"at" command

  • Thread starter Thread starter Blair
  • Start date Start date
B

Blair

Would anyone know of a reason why this: at 10:00 shutdown -r -f
would not work? I have Win XP Pro sp1, patched to the latest. I tried
same on windows 2000, same result. For the Win 2000, I used the Win XP
shutdown.exe. Both worked from the command line, just fine, but not
when using the "at" command. Any imput would be great!
Thanks!
 
Why not just create a JOB in the Windows Task Manger ?

%windir%\tasks

Dave



| Would anyone know of a reason why this: at 10:00 shutdown -r -f
| would not work? I have Win XP Pro sp1, patched to the latest. I tried
| same on windows 2000, same result. For the Win 2000, I used the Win XP
| shutdown.exe. Both worked from the command line, just fine, but not
| when using the "at" command. Any imput would be great!
| Thanks!
 
Shutdown
Enables you to shut down or restart local or remote computers one at a time.

Syntax
shutdown [/i | /l | /s | /r | /a | /p | /h | /e] [/f] [/m \\ComputerName]
[/t XXX] [/d [p:] XX:YY [/c "Comment"]]

Parameters
/i
Displays the Remote Shutdown Dialog box. The /i option must be the first
parameter you type, and all those following it will be ignored.
/l
Logs off the current user immediately, with no time-out period. You cannot
use /l with /m \\ComputerName or /t.
/s
Shuts down the computer.
/r
Restarts the computer after shutdown.
/a
Cancels a shutdown, effective only during the time-out period. You may use
a only with /m \\ComputerName.
/p
Turns off the local computer only (not a remote computer), with no
time-out period or warning. You can use /p only with /d. If your computer
does not support power off functionality, it will shut down when you use /p,
but the power to the computer will remain on.
/h
Puts the local computer into hibernation, assuming that hibernation is
enabled. You can use h only with /f.
/e
Enables you to document the reason for the unexpected shutdown on the
target computer.
/f
Forces running applications to close without warning users in advance.
Caution

a.. Using the /f option might result in loss of unsaved data.
/m \\ComputerName
Specifies the target computer. Cannot be used with the /l option.
/t XXX
Sets the time-out period or delay before a restart or shutdown to XXX
seconds, causing a warning to display on the local console. You can specify
0-600 seconds. If you omit /t, the time-out period defaults to 30 seconds.
/d [p:]XX:YY
Lists the reason for the system restart, shutdown, or power off. The
following table describes the parameter values. Value Description
p: Indicates that the restart or shutdown is planned. If you do not
use the p: option, Shutdown Event Tracker assumes that the restart or
shutdown is unplanned.
XX Specifies the major reason number (0-255).
YY Specifies the minor reason number (0-65535).

/c "Comment"
Enables you to comment in detail about the reason for the shutdown. You
must first provide a reason using the /d option. You must enclose comments
in quotation marks. You can use a maximum of 127 characters.
/?
Displays help, including a list of the major and minor reasons that are
defined on your local computer, at the command prompt. Simply typing
shutdown with no parameters also displays help.
 
Ummm...

search path maybe....

If, for whatever reason, you don't want to set this up in the task
scheduler (although it will show up there). The correct syntax would
be:
AT 22:00 /every:m,t,w,th,f,sa,su "c:\winnt\sys
tem32\shudown -r -f"

Warren
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top