Discussion Locked

Auto Rebooting a Win2K Terminal Server

0 helpful
8 replies
Closed to new repliesThis discussion is closed. It stays readable, but it takes no new replies.

I am trying to schedule nightly reboots of my Win2K Terminal Server (w/SP2) using the SHUTDOWN utility from the Win2K Resource Kit. The script looks like this - SHUTDOWN /L/R/Y/C
Unfortunately, the server does not reboot. It just shuts down to the point where it says "It is now safe to turn off your computer". Does anyone have any ideas?

8 replies

by jwilczyn

Check: HOW TO: Use the Remote Shutdown Tool to Shut Down and Restart a Computer in Windows 2000 (Q317371)
Shutdown.exe uses the following syntax:
shutdown \\ computername /l /a /r /t: xx " msg " /y /c
You can use the following switches with Shutdown.exe:
\\computername : Use this switch to specify the remote computer to shut down. If you omit this parameter, the local computer name is used.

/l (Note that this is a lowercase "L" character): Use this switch to shut down the local computer

/a : Use this switch to quit a shutdown operation. You can do this only during the time-out period. If you use this switch, all other parameters are ignored.

/r : Use this switch to restart the computer instead of fully shutting it down.

/t: xx : Use this switch to specify the time (in seconds) after which the computer is shut down. The default is 20 seconds.

" msg " : Use this switch to specify a message during the shutdown process. The maximum number of charactersthat the message can contain is 127.

/y : Use this switch to force a "yes" answer to all queries from the computer.

/c : Use this switch quit all running programs. If you use this switch, Windows forces all programs that are running to quit. The option to save any data that may have changed is ignored. This can result in data loss in any programs for which data is not previously saved.

by jwilczyn

Examples
To shut down the local computer in two minutes and display a "The computer is shutting down" message, use the following line in a batch file or type it at a command prompt, and then press ENTER:

shutdown /l /t:120 "The computer is shutting down" /y /c
To cancel the shutdown process, type the following line at the command prompt, and then press ENTER:
shutdown /l /a /y
To shut down and restart a remote computer named "Support," use the following line in a batch file or type it at a command prompt, and then press ENTER:

shutdown \\support /r
To schedule the local computer to shutdown and restart at 10:00 P.M., type the following line at a command prompt, and then press ENTER:

at 22:00 shutdown /l /r /y /c
To schedule the local computer to shutdown and restart at 6:00 P.M. every weekday, type the following line at a command prompt, and then press ENTER:

at 18:00 /every:M,T,W,Th,F shutdown /l /r /y /c

by jwilczyn

Troubleshooting
The specified computer may not shut down when you use the Shutdown.exe tool to shut it down. This behavior can occur if the Unlock Computer dialog box appears on the desktop, or if the computer is locked. For additional informationabout how to resolve this issue, click the article numbers below to view the articles in the Microsoft Knowledge Base:
Q307635 Remote Shutdown Results in Logoff When Unlock Computer Dialog Box Is Displayed
Q288180 The ExitWindowsEx() Function May Not Log Off the User or Shut Down the Computer If the Computer is Locked

by ed

I have already read through the Q article - Q317371. I am doing exactly what Microsoft recommends to do but it is not working. The server shuts down but does not restart.

This discussion is closed to new replies.