Server Fault is a question and answer site for system and network administrators. 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

Last week I installed Ubuntu and tried to get it to boot with Wake On Lan.

I rerouted all incoming packets at port 9 to the server. When it's the magic packet the server will boot. All went well until I tried it the next day from a different location. It wouldn't work. So I started Googling and did some tests and found out the server won't respond to the magic packet after x amount of minutes.

I've got telnet access to my router, if there is anything I need changed there.

share|improve this question

migrated from Oct 14 '10 at 11:25

This question came from our site for professional and enthusiast programmers.

Would be useful if you gave some more details. Are the servers you want to wake and the system issuing the magic packet on the same subnet with no routers in between them? Not sure what you mean by server not responding after x amount of minutes. How many is x? What googling and testing did you do? – dunxd Oct 14 '10 at 11:35
Yes i've did the following tests with success: Wake up server on same subnet without any routers in between Wake up server from internet so with router in between x amount of minutes is unknown, but it did work within 20 minutes after server shut down. After that it wont respond anymore to the magic packets. – user57121 Oct 14 '10 at 11:53

If your router is configured to forward the WOL packet to your sleeping computer, it needs to be able to discover the computer's MAC address based on the IP address, which is what the ARP protocol does. However, with the computer off, ARP won't work, so once the router's ARP cache becomes stale the relevant entry is removed and you're out of luck (that apparently takes 20 minutes in your case).

Some routers let you configure this ARP mapping statically, or use the static IP configuration as an ARP mapping as well, or contain their own WOL tool to do the job (e.g. Tomato and DD-WRT firmwares) - you'll have to check yours to see if it's supported.

Another option is to forward the WOL packet to the broadcast address (such as, if that's your subnet's address), but this too is not supported on all routers.

share|improve this answer
The network-directed broadcast address for a subnet is – deemer Mar 25 '11 at 2:01

If you are using an enterprise grade switch or router you may want to look at the following two directives:

ip directed-broadcast


ip forward-protocol

These directives are mostly prevalent on Cisco or other vendors that adopt a Cisco-like CLI. The ip directed-broadcast directive instructs the switch/router to forward any packets destined to a subnet's broadcast address as if it were a unicast packet. Meaning, your UDP packet destined for (for subnet would be forwarded along to the destination subnet as if it were addressable. Once the packet reaches the hop (router/switch) that is directly connected to, your ip forward-protocol directive will take over.

Since is a broadcast address, there is no MAC address associated with it. Therefore, the switch will have to explode the destination MAC address to FF:FF:FF:FF:FF:FF. Meaning, the switch/router will have to send the packet to all the operational ports on the switch (i.e. layer 2 broadcast). The ip forward-protocol directive does just that. This eliminates the need to store static ARP entries in your router/switch's ARP table. Note, you do not want to use the ip helper-address directive (unless you need to) because it is limited to forwarding a few common udp protocols like NTP, NetBIOS, etc. Wake-on-LAN is not one of them.

Furthermore, we have been experiencing problems in our workplace with BIOS settings on machines, and different NICs. In some cases, WoL will work only once and then fail subsequent times. Completely disconnecting the PC from the wall (network & power cable), allowing the capacitors on the motherboard to discharge, and then reconnecting these PCs appeared to remedy the issue. However, this is no solution. We are currently in the process of investigating these anomolies with our vendor (Dell). Hope this helps.

share|improve this answer

Some routers wont forward the wake on lan packets to your local network, you will need to check to see if your router will

share|improve this answer

Your Answer


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.