Put WHS to sleep (and wake it up)

Windows Home Server logo

I have been using a Windows Home Server at home for more than 6 months: it backups our three computers, stores my whole music collection on an SMB share and shares it as a UPnP media library... I love it.

Even if the server is powered by a - relatively - power saving Intel Atom, it wouldn't feel right to keep it on all the time. In order to save some power there's a really effective and simple WHS plug-in: LightsOut.

The plug-in is easily installed through the standard procedure (copy the .msi installer to \\homeserver\software\add-ins and then install it from the WHS connector settings dialog).

On the LightsOut settings panel you will be able to set how the plug-in should behave: usually the best thing is to keep the server running during the time span when it should backup your computers. The plug-in will never shutdown the server when at least another computer is on. Only after a certain time of inactivity (after the last monitored computer is offline) the server can be told to shuwdown, enter hibernation or sleep.

At home, my server is setup to shut down after 30 minutes of inactivity.

Another great feature is the "activity graph" that shows exactly which computers were running during the time the server was on. This can be quite useful to check whether the server was running at a certain time or to verify that LightsOut is working correctly.
Plus, it's a nice looking graph, what do you want more?  :)

Ok, now the server shuts down...

...how do I wake it up again without having to walk to the closet?

There's a magical feature in most modern motherboards/ethernet adapters which allows you to remotely "wake up" a computer. This feature is called "wake on lan" and works by sending a specially crafted ethernet packet that will be interpreted by the slumbering network card and start up the whole PC. This of course works only if the computer is off, but powered. If you unplug the power cable and plug it in again it won't work because this will leave the motherboard unpowered (the "power led" on your motherboard must be on, so to speak).

Download this free Wake-on-LAN application ant put it somewhere on your client computer. First of all you need to determine your server adapter's MAC address: to do so, use the MCGETMAC.EXE program that comes with the Wake-on-LAN program. Launch it from the command line giving the server's IP address as parameter (this address probably has been automatically assigned by your DHCP server, so find it out via a remote desktop session to the WHS):

mcgetmac.exe 192.168.1.12

This yields the following data:

Get MAC v1.1 Copyright (c)2001-2008, MATCODE Software.
Web: http://www.matcode.com
Author: Vitaly Evseenko, ve@matcode.com

Name: HOMESERVER
IP address: 192.168.1.12
Ethernet MAC address: 00:1C:C0:B4:E4:3A

The last address is the important information. Now create a simple batch file with a text editor that will launch the Wake-on-LAN program:

mc-wol.exe 00:1C:C0:B4:E4:3A

And that's it. Now create a shortcut to this batch file somewhere on your start menu and you're ready to wake up your Windows Home Server from anywhere.

Wake up your windows home server remotely