Super User is a question and answer site for computer enthusiasts and power users. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

My server is on an APC UPS via a USB cable. When the power goes out, I have 10 to 15 minutes to shut everything down gracefully. This is easy for the server but I also have a personal PC on the UPS as well. Chances are good it will be in a state of hibernation when the power goes out.

Using a VBScript or batch file that I can run from the server, how can I:

  1. Wake the Windows XP PC out of hibernation
  2. Log on
  3. Shut it down (I can use the built in shutdown exe for this)
share|improve this question
up vote 4 down vote accepted

You can do this with Wake on LAN functionality (WoL). You can read about how to set it up for XP here. This is all assuming your hardware BIOS/MOBO/NIC support WoL functionality, however most relatively modern machines do.

Sending the magic packet will wake the PC from hibernation and then you can use the shutdown command from your server to remotely shutdown the PC. You can do this all from VBScript. You can ping the PC to see if its up, before you send the shutdown command. FYI, you might have to test this out, as just because the NIC is up, doesnt mean the machine is ready to accept a shutdown command. You might have to wait a minute of two after the interface is responding before you send the commmand.

share|improve this answer

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .