Solved

SCCM 2012 R2 auto shutdown computer at specific time

Posted on 2016-09-01
4
132 Views
Last Modified: 2016-09-26
i want to make the SCCM 2012 R2 shutdown computers that stay power on in the night, but i wat to have a report to view what computers stay power on or what computers shutdown whit the task of SCCM.

i test multiples 3 party options but i need to use SCCM for a corporate requeriment.
0
Comment
Question by:wolf77
  • 3
4 Comments
 
LVL 17

Expert Comment

by:Mike T
ID: 41781420
Hi,

The simplest way is to create a PowerShell script and deploy that, so it creates a scheduled task. You have to decide if you want to brute force power off if the machine is logged on still, but other than that it's fairly straight-forward.

As far as I know there's no native way, using Power Management although that would be very nice!

For even more control you can use the script together Compliance (DCM) which offers reports of machines that do no comply, but otherwise you can use deployment reporting to monitor delivery of the script.

As far reporting which machines actually power off, I think that would be best done as another function in the script.

Mike
0
 

Author Comment

by:wolf77
ID: 41788613
Thks, i cant find a way to shutdown a Computer  Power Management, but im going to try DCM
0
 
LVL 17

Accepted Solution

by:
Mike T earned 500 total points (awarded by participants)
ID: 41788683
Yes - I'm not sure why MS have no option using Power Management, but in the absence of that there's PowerShell as I said. The Stop-computer cmdlet is one option, as discussed here: https://blogs.technet.microsoft.com/heyscriptingguy/2011/04/01/scripting-wife-uses-powershell-to-shut-down-computers.
I know shutdown.exe exists but it's easy to abort it and is external.

I did find a script to do this but I can't see to find it again! Here's how to create a schedule task anyway:

schtasks /CREATE /TN Shutdown /RU "SYSTEM" /TR "Powershell \"C:\Scripts\Shutdown.ps1\"" /SC ONSTART

Mike
0
 
LVL 17

Expert Comment

by:Mike T
ID: 41815717
There were no other answers and that is the only way that I know of; others require 3rd party tools which is not a good step if you can do something natively.
0

Featured Post

Simplifying Server Workload Migrations

This use case outlines the migration challenges that organizations face and how the Acronis AnyData Engine supports physical-to-physical (P2P), physical-to-virtual (P2V), virtual to physical (V2P), and cross-virtual (V2V) migration scenarios to address these challenges.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

You might have come across a situation when you have Exchange 2013 server in two different sites (Production and DR). After adding the Database copy in ECP console it displays Database copy status unknown for the DR exchange server. Issue is strange…
Adding Computers to AD groups through an SCCM Task Sequence
This tutorial will walk an individual through the steps necessary to join and promote the first Windows Server 2012 domain controller into an Active Directory environment running on Windows Server 2008. Determine the location of the FSMO roles by lo…
This tutorial will walk an individual through the process of transferring the five major, necessary Active Directory Roles, commonly referred to as the FSMO roles from a Windows Server 2008 domain controller to a Windows Server 2012 domain controlle…

791 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question