Still celebrating National IT Professionals Day with 3 months of free Premium Membership. Use Code ITDAY17


Shutdown script for Windows 2003 servers.

Posted on 2008-10-15
Medium Priority
Last Modified: 2012-05-05
I have 21 servers that I wish to shutdown but initiating a shutdown script.  However I am stuck on two things;

A) Should I use Vbscript or a simple batch file

B) Depending on the answer above what is the exact syntaxt that will work?    

I have a rudimentary understanding of the shutdown command (eg. shutdown -f -t 00] but I am not quite sure how to send this to remote machine  but I know the functionality is there.  Thanks you.
Question by:every1isevil2
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
  • 2

Expert Comment

ID: 22723464
The /m \\servername is the switch to specify another compuer.

Author Comment

ID: 22723495
Would you be able to create an exact syntax sample for me?  And how can I add multiple servers to that?

/m \\servername /m \\servername  OR /m \\servername \\servername

Thanks again.

Accepted Solution

mikef147 earned 600 total points
ID: 22723526
I believe you can only specify 1 server at a time per line, so if you wanted to script for 21 servers you could use a simple batch file and do, for example

shutdown /m \\server1
shutdown /m \\server2

If you want a specific time delay, you can add in /t xxx (# of seconds).   If you want them to shutdown and reboot, add the /r switch.  

For example, this should shutdown and reboot server1 after 60 seconds:   shutdown /r /t 60 /m \\server1


Author Closing Comment

ID: 31506400
Great thank you.

Featured Post

Windows Server 2016: All you need to know

Learn about Hyper-V features that increase functionality and usability of Microsoft Windows Server 2016. Also, throughout this eBook, you’ll find some basic PowerShell examples that will help you leverage the scripts in your environments!

Question has a verified solution.

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

I've always wanted to allow a user to have a printer no matter where they login. The steps below will show you how to achieve just that. In this Article I'll show how to deploy printers automatically with group policy and then using security fil…
When you receive another warning that your shared drive is almost full and you have asked your users to clean out old files again and again, here is a single command that may help. This command will place all the files that have not been used rec…
Video by: ITPro.TV
In this episode Don builds upon the troubleshooting techniques by demonstrating how to properly monitor a vSphere deployment to detect problems before they occur. He begins the show using tools found within the vSphere suite as ends the show demonst…
Sometimes it takes a new vantage point, apart from our everyday security practices, to truly see our Active Directory (AD) vulnerabilities. We get used to implementing the same techniques and checking the same areas for a breach. This pattern can re…

688 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