So you want to have your machines go to sleep when they are not working and then be able to remotely connect to them and have them automagically respond? This is cross platform and can potentially work on any computer.
The computers can be in a totally powered off state (but still connected to the power outlet) and woken up all the way to a simple stand-by mode. This is called Wake On LAN. According to Wikipedia, Wake-on-LAN is an Ethernet computer networking standard that allows a computer to be turned on or woken up by a message. The message is usually sent by a simple program executed on another computer on the local area network. Wake-on-LAN is also known as Wake on LAN, WOL, or sometimes WoL. It may also be known as Remote Wake-Up or RWU.
Before we begin, we should go over the system requirements for using Wake On LAN. The system you are launching the Wake On LAN command from does not need to match the requirements — just the machine you will be waking up. Here they are, right from the same Wikipedia page:
Wake-on-LAN support is implemented on the motherboard of a computer and the network interface, and as such, is not dependent on the operating system running on the hardware, although the operating system can sometimes control the Wake-on-LAN behavior. If the network interface is a plug-in card rather than being integrated into the motherboard, the card may need to be connected to the motherboard by a cable. Motherboards with an embedded Ethernet controller which supports Wake-on-LAN do not need a cable.
If you are having issues with WOL, check your BIOS setting and make sure if the Ethernet card is a add-on card, it is still connected to the motherboard via a cable.
There are many ways to trigger a Wake On LAN event and we will be exploring how to do Wake on LAN using the Mac Address of the machine in question. The MAC address is a unique address given to your network adapter or NIC. To find your MAC address, you can dig into your network adapter’s properties. But to find a remote machine’s MAC address or yours easily, we can use this simple command line application MCGETMAC.EXE. Download that and run it from the command line like so:
You need to go to Start ““ Run and type CMD then navigate to the directory you stored MCGETMAC.exe and then run it using either of these two syntaxes:
MCGETMAC.exe IP Address
So I could use MCGETMAC.exe 127.0.0.1 to return my local machine’s MAC address or I could use MCGETMAC.exe KarlXP to grab it. Once you have it, store it in a safe place. Next, we will need to download MC-WOL.EXE both of these files are from here.
Save that EXE file to the same place you have saved MCGETMAC.exe for ease of use. Now you can go back to your CMD window and type MC-WOL.exe and the MAC address. In my case, I typed MC-WOL.exe 00:0C;F1:F9:6F:F2 and hit Enter. This was my result:
The “Magic Packet” was sent to my remote machine and I was able to wake it up. Now I can include these commands in batch files or scripts and save power and money while I am at it!
And for some more good reading, check out this post on 3 ways to shut down your computer over the Internet.
Have you ever used the Wake on LAN feature with the mac address? Any luck getting it to work properly?