Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

I am attempting to reboot a Windows XP SP2 box (acting as a server, yeah I know winxp isn't a great choice but currently I am unable to change the OS) on a daily schedule.

The code I am using is as follows:-

shutdown -r -f -t 5 -c "Planned auto restart" -d p:4:1 > C:\RebootOutput.txt

This appears to have been working correctly in the past, running at 3am each morning, however since the time has been changed to 12.05am then 11.55pm, it appears to have not run at all, the log file indicating the error:-

A system shutdown is in progress.

I have confirmed that the Run as user is set correctly with the correct password. Additionally I have tried setting 'Run only if logged in' which failed to correct the error.

When run manually, however, it appears to run correctly!

If anyone has any ideas what this might by, I would be very grateful!

share|improve this question

1 Answer 1

Does it work if you try shutting down the machine with PsShutdown? I use PsShutdown as a scheduled task to shut down ~600 machines at work each night, sheduling the schtasks CLI command in XP.

And it is probably stating the obvious, but does the user the task is being scheduled to run as have permission to shut down the machine in question?

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.