1. Create your list of servers in a text file one per line with no extra spaces or characters.
2. Run the batch file under an ID with administrative access to the servers.
NOTE: This is the bare script to perform the action. You may want to add logging and error checking to the script. Adjust the shutdown command line meet your requirements.
<pre>
@echo off
REM --- Parse list of servers
for /f %%a in (pathServerName.txt) do CALL :RbtMe %%a
goto :DONE
:RbtMe
REM --- Restarting remote system.
shutdown -r -t 05 -c "Rebooting for BLAH" -f -m %1
GOTO :EOF
:DONE
</pre>
------------------------------------------------------------------------------------------------------------------------
See <a href="http://www.computerperformance.co.uk/w2k3/shutdown.htm">this website</a> for information on remote shutdown/reboots using the Windows shutdown command.
Last Wiki Answer Submitted: September 3, 2010 4:17 pm by Labnuke9932,645 pts.
All Answer Wiki Contributors: Labnuke9932,645 pts.
If you live outside the United States, by submitting your email address you consent to having your personal data transferred to and processed in the United States.