December 24th, 2012

PowerTip: Use PowerShell to Shut Down a Remote Computer

Doctor Scripto
Scripter

Summary: Use Windows PowerShell to shut down a remote computer.

Hey, Scripting Guy! Question I need to shut down a remote computer, but the account that I am logged on to does not have rights. What should I do?

Hey, Scripting Guy! Answer Use the Stop-Computer cmdlet and specify both the name of the remote computer and the credentials to use for the operation. When the cmdlet runs, you will be prompted for a password, as shown here.

Stop-Computer –computer DC1 –Credential nwtraders\administrator

 

Author

The "Scripting Guys" is a historical title passed from scripter to scripter. The current revision has morphed into our good friend Doctor Scripto who has been with us since the very beginning.

0 comments

Discussion are closed.