Skip to main content

Shutdown Command Via Command Prompt

The 'Shutdown' Command Becomes More Flexible and Automated when used from the Command Prompt.

To Run the 'Shutdown' command from the command prompt, go to 'Start > Run', type 'cmd', and press 'Enter'.
In the black box (the command prompt) type 'Shutdown' and the Switches you want to use with the 'Shutdown' command.
You have to use at least one switch for the shutdown command to work.

The Switches :-
The 'Shutdown' command has a few options called Switches. You can always see them by typing 'shutdown -?' in the command prompt if you forget any of them.

-i: Display GUI interface, must be the first option
-l: Log off (cannot be used with -m option)
-s: Shutdown the computer
-r: Shutdown and restart the computer
-a: Abort a system shutdown
-m \\computernameRemote computer to shutdown/restart/abort
-t xx: Set timeout for shutdown to xx seconds
-c “comment”: Shutdown comment (maximum of 127 characters)
-fForces running applications to close without warning
-d [u][p]:xx:yy: The reason code for the shutdown u is the user code p is a planned shutdown code xx is the major reason code (positive integer less than 256) yy is the minor reason code (positive integer less than 65536)

Note :- I’ve noticed using a switch with a '-' sign doesn’t work sometimes.
If you are having trouble try using a '/' in place of '-' in your switches.

Examples :-
shutdown –m \\computername –r –f
This command will restart the computer named computername and force any programs that might still be running to stop.

shutdown –m \\computername –r –f –c “I’m restarting your computer. Please save your work now.” –t 120
This command will restart the computer named computername, force any programs that might still be running to stop, give to user on that computer amessage, and countdown 120 seconds before it restarts.

shutdown –m \\computername –a
This command will abort a previous shutdown command that is in progress.

Using A Batch File :-
You can create a file that performs the shutdown command on many computers at one time.

In this example I’m going to create a batch file that will use the shutdown command to shut down 3 computers on my home network before I go to bed.

Open 'Notepad' and type the shutdown command to shut down a computer for each computer on the network.
Make sure each shutdown command is on its own line.
An example of what should be typed in notepad is given below-

shutdown –m \\computer1 –s
shutdown –m \\computer2 –s
shutdown –m \\computer3 -s

Now I’ll save it as a batch file by going to file, save as, change save as type to all files, give the file a name ending with '.bat'. I named mine 'shutdown.bat'.
Pick the location to save the batch file in and save it.

When you run the batch file it’ll shutdown computer 1, 2, and 3 for you.

You can use any combination of shutdown commands in a batch file.



LIKE,COMMENT AND SHARE MY THIS ARTICLE 

AND BE A FAN OF THIS BLOG.

Like us on facebook Just click here.

Comments

Popular posts from this blog

Hack Sify,Reliance,Beam Cable - Speed Upto 10 MBPS

I got many requests on how to speed up the internet speed, although some buddy's are using the broadband connection, they wont get the maximum internet speed to browse or to view the online videos... so iam posting this article article specially for them. First Download this ETHERNET Ip Sniffer called   ETHERDETECT Connection-Oriented Packet Sniffer And Protocol Analyzer.by using this tool you can easily speed up net speed. Use the tool to Scan Ip's in your network,Keep Scanning till you get some 200 Ip's .. Then just change the last 3 digits of your IP Address with the IP's you get In that scanner !! NOTE:Please save your Ip address somewhere so as to get back to your original ip ! It will say "Ip conflict" error,keep trying with other Ip's untill you succeed. Sometimes when you will change your Ip you will get same speed ...in that case ..try another ip Download Link~:.. CODE http://adf.ly/9L2dK System Requirements: Processor...

Edit tiles in Windows 8

If you’ve recently installed or upgraded to Windows 8 and have started customizing programs onto its new Start Menu UI, you’ll notice that the program icons are the same old icons placed in an oversized box. You’ll see the program name under it and will be in awe at  how out of place the newly added icons are with the rest   of the Windows 8 theme. We’ve found a handy program to spruce things up by  creating awesome-looking tiles that match the look of Windows 8 apps  on the Start Menu, something like what you see below. And you can get that look using   OblyTile . First thing’s first, the icons you see above are works from users of deviantART. OblyTile only sets up your tiles; you have to provide the icons or images for the tile. But not to worry, we’ll provide you with  a few links which we’ve found to recreate the look and feel  of the screenshot you see above. Getting Started With OblyTile Run OblyTile (no insta...

STEALING PASSWORD WITH GOOGLE HACK

Google is a treasure trove full of important information, especially for  the underground  world. This Potential fact can also be utilized in the data for the username and password stored on a server. If the administrator save important data not in the  complete system authentifikasi folder, then most likely be reached by the google search engine. If data is successfully steal in by the unauthorized person, then the will be in misuse. Here, some google search syntax to crawl the password: 1.  "Login: *" "password =*" filetype: xls  (searching data command to the system files that are stored in  Microsoft Excel ) 2.  allinurl: auth_user_file.txt  (to find files auth_user_file.txt containing password on server). 3.  filetype: xls inurl: "password.xls"  (looking for username and password in ms excel format). This command can change with admin.xls) 4.  intitle: login password  (get link to the  login ...