WOL only works....sometimes

PurdueRy

Lifer
Nov 12, 2004
13,837
4
0
I can always get wake on lan to work within my network it seems. However, when I move out of my network it seems to be hit or miss. Sometimes it works no problem...othertimes nothing at all.

I opened the port the magic packet is transmitted on the LAN and directed it at the static IP address of my computer
My WAN IP address has stayed the same
my MAC address is constant(obviously)

I send the magic packet to my own WAN IP address with subnet mask 255.255.255.255 and the port which I opened.

Like I said, sometimes my computer turns on, sometimes it doesn't.

I used wireshark to monitor my network and it appears that the magic packet is being received by the router. However, when it doesn't work the router responds with

"Who has 192.168.1.100? Tell WAN IP address"

The 192.168.1.100 is the static IP address of the computer I am trying to turn on. The router knows this because the port I send the message on is set to forward to 192.168.1.1

What I don't get, is it appears that the IP address really doesn't matter when on the local network. This makes sense because the router doesn't assign an IP until the computer is booted. So how should I forward this port so that the router knows how to broadcast it? The router will not let me direct it via a generic 192.168.1.1 message.

Apologies if anything I have stated is incorrect, I know I'm really close to getting this working 100%....just one bug left.
 

PurdueRy

Lifer
Nov 12, 2004
13,837
4
0

The program that sends the magic packet has the MAC address of my computer at 192.168.1.100. The router only brings up 192.168.1.100 because of the port forwarding policies on my netgear router which state to open a port (which the magic packet transmits to) for 192.168.1.100. I am guessing this has something to do with the router knowing the IP address of my computer was 192.168.1.100 sometimes and othertimes it doesn't "remember" and hence why I get the message I stated in the OP.
 

spidey07

No Lifer
Aug 4, 2000
65,469
5
76
The program that sends the magic packet has the MAC address of my computer at 192.168.1.100. The router only brings up 192.168.1.100 because of the port forwarding policies on my netgear router which state to open a port (which the magic packet transmits to) for 192.168.1.100. I am guessing this has something to do with the router knowing the IP address of my computer was 192.168.1.100 sometimes and othertimes it doesn't "remember" and hence why I get the message I stated in the OP.

You have an ARP timeout. The "router" is ARPing for .100. See if you can do a static ARP on the router to tie the IP/MAC together. Crossing layer3 boundaries like this is why wake on lan is never used. It's a failed protocol.
 
Last edited:

PurdueRy

Lifer
Nov 12, 2004
13,837
4
0
What router do you have? Possibly run DD-WRT or Tomato on it?

Anyway, here's the tomato version of static ARP and broadcasting the magic packet to all...

http://forums.anandtech.com/showpost.php?p=27324103&postcount=79

I am running off a WNDR3700. I could attach the desktop to the Asus RT-N16(wired off the WNDR3700) which is running Tomato. I just tried DD-WRT for the WNDR3700 and file transfer performance took a fairly significant hit. So I went back to factory firmware.
 

PurdueRy

Lifer
Nov 12, 2004
13,837
4
0
Can someone tell me how the situation for WOL differs for intranet vs. internet? How come I can always send a message out on the intranet and have the router pass on the message to wake up the computer but the router cannot always pass the message to wake up my computer from the internet.
 

imagoon

Diamond Member
Feb 19, 2003
5,199
0
0
WoL is data link protocol and is not layer 3 / routable protocol. NAT is an IP protocol which is layer 3. As far as WoL is concerned... IP = nothing / irrelevant

Magic packet had some revisions made a bit later that allowed it to embedded in other layers but in most cases when a computer is off, it will not respond to ARP broadcasts so the IP will not be kept in the ARP cache long (typically only seconds,) hence the note above that you may need to enter a static IP and a static ARP address so the router can know where to send it.
 

Ichinisan

Lifer
Oct 9, 2002
28,298
1,235
136
I usually assign static IPs on my LAN starting with .99 and counting down.

I never understood why so many consumer-grade Linksys routers have port forwarding options, but no static DHCP option. So, if you configure forwarding and it works, the LAN IPs will randomly change and the incoming traffic will be forwarded to the wrong LAN device...so you pretty-much have to go with manual IPs that are outside the router's DHCP range.

Of course, most brands have the static DHCP option.

I currently use a Linksys WRT54GL w/ DD-WRT. With remote web administration enabled, I can log-in to the configuration web page and wake specific LAN devices from there.
 

PurdueRy

Lifer
Nov 12, 2004
13,837
4
0
I usually assign static IPs on my LAN starting with .99 and counting down.

I never understood why so many consumer-grade Linksys routers have port forwarding options, but no static DHCP option. So, if you configure forwarding and it works, the LAN IPs will randomly change and the incoming traffic will be forwarded to the wrong LAN device...so you pretty-much have to go with manual IPs that are outside the router's DHCP range.

Of course, most brands have the static DHCP option.

I currently use a Linksys WRT54GL w/ DD-WRT. With remote web administration enabled, I can log-in to the configuration web page and wake specific LAN devices from there.

Static IPs are assigned for all but my PS3 which, because of the wireless bridge, really doesn't like having a static IP assigned to it...odd but true.

Only problem is that Netgear doesn't give the option for a static ARP. I'll probably try to connect my desktop up to the Asus router running tomato which is connected to the netgear. Sounds like I should be able to get that working.
 

PurdueRy

Lifer
Nov 12, 2004
13,837
4
0
WoL is data link protocol and is not layer 3 / routable protocol. NAT is an IP protocol which is layer 3. As far as WoL is concerned... IP = nothing / irrelevant

Magic packet had some revisions made a bit later that allowed it to embedded in other layers but in most cases when a computer is off, it will not respond to ARP broadcasts so the IP will not be kept in the ARP cache long (typically only seconds,) hence the note above that you may need to enter a static IP and a static ARP address so the router can know where to send it.

Which is why I am wondering why intranet WOL messages always work no matter how long the computer has been off for. Internet WOL messages appear affected by ARP.
 

imagoon

Diamond Member
Feb 19, 2003
5,199
0
0
Which is why I am wondering why intranet WOL messages always work no matter how long the computer has been off for. Internet WOL messages appear affected by ARP.

In a WoL enabled computer, the NIC is on and running layer 1 (physical) and layer 2 (datalink). The WoL packet is sent to the datalink layer broadcast address (I think that is FF:FF:FF:FF:FF:FF) which is then sent to all devices on that lan segment. The NIC will see the packet and send "pwr_on" to the baseboard management or simply to the power switch depending on the system.