shutdownHave you ever been using Remote Desktop in windows to a client machine and need to reboot?

I do.  

I am often remoted in to computers installing updates.  If you have done this much on client machines you realize that on XP and Windows 7 you don’t have the option to reboot only shut down.  Well if I am remoted into a computer shutting down isn’t what I want to do.

Microsoft has included shutdown.exe to help people like us who need to reboot remotely.

To shutdown a PC running Windows XP or 7

 Open a command prompt (Click start run cmd) and  type in shutdown and the proper switches.   shutdown -t 0 -r -f

-t 0 means time to shut down 0 seconds.

-r means restart

-f forces all applications to terminate.

Below is information provided by Microsoft Technet.

Syntax

shutdown 

[{-l|-s|-r|-a}] [-f] [-m [\\ComputerName]] [-t xx] [-c message] [-d[u][p]:xx:yy]

Switches

You can use the following switches with Shutdown.exe:

-l Logs off the current user, this is also the defualt. -m ComputerName takes precedence.

-s Shuts down the local computer.

-r Reboots after shutdown.

-a Aborts shutdown. Ignores other parameters, except -l and ComputerName. You can only use -a during the time-out period.

-f Forces running applications to close.

-m [\\ComputerNameSpecifies the computer that you want to shut down.

-t xx Sets the timer for system shutdown in xx seconds. The default is 20 seconds.

-c message Specifies a message to be displayed in the Message area of the System Shutdown window. You can use a maximum of 127 characters. You must enclose the message in quotation marks.

-d [u][p]:xx:yy Lists the reason code for the shutdown. The following table lists the different values.

Leave a comment

Your email address will not be published. Required fields are marked *