Lansweeper logo
Home Download Features Demo Buy now Help Support forum
 
    Most requested support articles:
  Lansweeper troubleshooting guide.
  The RPC server is unavailable. (Exception from HRESULT: 0x800706BA)
  WMI Access is denied. (Exception from HRESULT: 0x80070005 (E_ACCESSDENIED))
  How to configure the windows firewall using group policies.
  Support:  
 support@lansweeper.com  
Skype: Lansweeper  
  Mo-Fri 9h-17h CET  
Welcome Guest Search | Active Topics | Log In | Register

Untag as favorite
WOL.exe in different subnets - directed broadcast packet
wgknowles
#1 Posted : Monday, January 18, 2010 10:23:31 PM

Rank: Premium user

Groups: Premium Users
Posts: 34
Location: California
In trying to delete a single post, I accidentally deleted the entire thread... I'm recreating it here from google's cache:

In Lansweeper 3.5.2 the link for Network Wake on Lan will only wake up computers in the same subnet. The way to Wake up computers in different subnets is via "Directed Broadcast" Unfortunately the utility included in 3.5.2 (WOL.exe) does not generate directed broadcast packets.

Lansweeper support says in the next version you can specify a custom action for WOL
default : wol.exe {mac}


But for now, here's a simple way to get WOL to work across subnets in 3.5.2:

1)Download poweroff: http://users.telenet.be/jbosman/applications.html
2)Place poweroff.exe into the folder with the rest of the tools you use for custom actions
3)Backup & then modify your it-compdetail.aspx file as follows
Replace:

<td class="lijntje"><a href="javascript:runApp('wol.exe <%=replace(myrow("macaddress"),":","")%>','true');"><%=myrow("description")%></a>&nbsp;</td>

With: (Fix the Path to poweroff.exe to match your environment)

<td class="lijntje"><a href="javascript:runApp('cmd.exe /K \\\\SERVERNAME\\lstools\\poweroff.exe wol -ip <%=dscomputers.FieldValue("ip address", nothing)%> -subnet 255.255.255.0 -mac <%=replace(myrow("macaddress"),":","")%>','true');"><%=myrow("description")%></a>&nbsp;</td>

VOILA!
Enjoy waking up all those sleepy computers!


Here's a very in-depth technical background of WOL (for those who care):

WOL is primarily a Layer 2 function in that it is solely dependent on the MAC address.
The target NIC card doesn't care what protocol or port it is using. It is not actually parsed by a full protocol stack, all the target NIC card looks for is the unique WOL payload for that MAC Address. So if you can deliver this packet to the target NIC you are in business.

Because the PC is asleep, it will not have an IP address and will not respond to Address Resolution Protocols (ARPs) from the router. Therefore, only a local subnet IP broadcast packet will be transmitted on the broadcast segment.

If there is a Layer 2 switch between the router and the PC, which is true for most networks today, the switch does not know to which port the PC is physically connected. Only a Layer 2 broadcast or an unknown unicast frame is sent out to all switch ports. All IP broadcast packets are addressed to the broadcast MAC address.

That being said, WOL uses Directed Broadcast for delivery across subnets. The broadcast is typically sent as a UDP datagram to port 0, 7 or 9, or, in former times, as an IPX packet. The broadcast IP Address depends on your subnet configuration, but is typically x.x.x.255 The port and protocol are only relevant if you have firewalls in place that might block this traffic, or if you are attempting to set up port forwarding from the internet (NOT ADVISED).

An IP directed broadcast is a datagram which is sent to the broadcast address of a subnet to which the sending machine is not directly attached. The directed broadcast is routed through the network as a unicast packet until it arrives at the target subnet, where it is converted into a link-layer broadcast. Because of the nature of the IP addressing architecture, only the last router in the chain, the one that is connected directly to the target subnet, can conclusively identify a directed broadcast

If a Cisco interface is configured with the no ip directed-broadcast command, directed broadcasts that are otherwise exploded into link-layer broadcasts at that interface are dropped instead. The no ip directed-broadcast command is the default in Cisco IOS Software Release 12.0 and later.

IP directed broadcasts are used in the popular smurf denial of service attack. In a smurf attack, the attacker sends ICMP echo requests from a falsified source address to a directed broadcast address. This causes all the hosts on the target subnet to send replies to the falsified source. By sending a continuous stream of such requests, the attacker can create a much larger stream of replies. This can completely inundate the host, whose address is falsified.

If routers are configured to allow subnet-directed broadcasts, the additional configuration can mitigate security concerns.
Routers can be configured to allow only IP-directed broadcasts from specific servers, using a specified (preferrably non standard) UDP port number.


References:
http://www.cisco.com/en/...8084b55c.shtml#directed

http://en.wikipedia.org/wiki/Wake-on-LAN#See_also

http://blogs.technet.com...ing-wake-on-lan-wol.aspx
wgknowles
#2 Posted : Monday, January 18, 2010 10:27:20 PM

Rank: Premium user

Groups: Premium Users
Posts: 34
Location: California
A more sophisticated method is described in another post that allows for wol over the internet and across firewalls:
http://www.lansweeper.co...n-with-poweroffexe.aspx
john_e_wagner
#3 Posted : Tuesday, April 20, 2010 5:50:02 PM

Rank: Premium user

Groups: Premium Users
Posts: 23
Location: Ohio
Instructions for 4.0.

(Easy Way.)

go to http://users.telenet.be/...sman/applications.html.
Download poweroff.exe.
Copy poweroff.exe to actions folder.
Start webSweeper configuration utility, configuration, custom actions, computer actions.
Change Wake On Lan to: (Right below action path)
"
{actionpath}poweroff.exe wol -mac {mac} -ip {ipaddress} -subnet 255.255.255.0 -immediate
"
Save Options.
Done.

JW



john_e_wagner attached the following image(s):
Capture.JPG
SirArion
#4 Posted : Wednesday, April 21, 2010 7:22:40 PM

Rank: Premium user

Groups: Premium Users
Posts: 14
Location: Modesto, Ca
I downloaded poweroff, I have changed the WOL to the sugegested values, where is the WOL option supposed to appear in the web console?

Am I supposed to create a custom action in addition to changing the paths?
john_e_wagner
#5 Posted : Thursday, April 22, 2010 2:36:08 PM

Rank: Premium user

Groups: Premium Users
Posts: 23
Location: Ohio
There is a wake on lan line near the top of the screen. You should be able to create a custom action for this as well.

What version of lansweeper are you using?

jw
bpc
#6 Posted : Thursday, August 12, 2010 10:36:14 PM

Rank: Premium user

Groups: Premium Users, Member
Posts: 17
Location: United States
Good information, thank you for posting this. Does anybody have any good suggestions for enabling WOL within the BIOS for a large amount of computers, besides doing it 1-by-1 manually? Specifically for Dell computers in my case.
otp
#7 Posted : Friday, September 17, 2010 12:57:53 PM
Rank: Freeware user

Groups: Member
Posts: 1
john_e_wagner wrote:
Instructions for 4.0.

(Easy Way.)

go to http://users.telenet.be/...sman/applications.html.
Download poweroff.exe.
Copy poweroff.exe to actions folder.
Start webSweeper configuration utility, configuration, custom actions, computer actions.
Change Wake On Lan to: (Right below action path)
"
{actionpath}poweroff.exe wol -mac {mac} -ip {ipaddress} -subnet 255.255.255.0 -immediate
"
Save Options.
Done.

JW





Thank you for instructions. I have created custom action, but {mac} parameter does not return mac address. I tried with {macaddress} but it's not working.
Does anybody know which is the correct parameter for returning mac address?
Thanks.
cmaxinuk
#8 Posted : Friday, September 23, 2011 11:36:30 AM
Rank: Freeware user

Groups: Member
Posts: 2
Location: London
Greetings and thank you for this info.

I'm trying to use the WOL steps above on LanSweeper v 4.1.0.127.

My it-compdetail.aspx doesnt contain the line below, or any reference to "wol.exe".

<td class="lijntje"><a href="javascript:runApp('wol.exe <%=replace(myrow("macaddress"),":","")%>','true');"><%=myrow("description")%></a>&nbsp;</td>

Any suggestion are most welcome as I would really like to Wake up our computers on different subnets.

Many Thanks

Craig
cmaxinuk
#9 Posted : Friday, September 23, 2011 11:42:22 AM
Rank: Freeware user

Groups: Member
Posts: 2
Location: London
bpc wrote:
Good information, thank you for posting this. Does anybody have any good suggestions for enabling WOL within the BIOS for a large amount of computers, besides doing it 1-by-1 manually? Specifically for Dell computers in my case.



I think there is a Dell Bios tool that you could deploy to your workstations.
Dell Client Configuration Toolkit - not sure if can help.
Lansweeper
#10 Posted : Tuesday, September 27, 2011 9:53:47 AM

Rank: Administration

Groups: Administration, Premium Users
Posts: 10,369
cmaxinuk wrote:
Greetings and thank you for this info.

I'm trying to use the WOL steps above on LanSweeper v 4.1.0.127.

My it-compdetail.aspx doesnt contain the line below, or any reference to "wol.exe".

<td class="lijntje"><a href="javascript:runApp('wol.exe <%=replace(myrow("macaddress"),":","")%>','true');"><%=myrow("description")%></a>&nbsp;</td>

Any suggestion are most welcome as I would really like to Wake up our computers on different subnets.

Many Thanks

Craig

In version 4.x you can change the wol location and command from the configuration tool.
danielm
#11 Posted : Wednesday, November 23, 2011 7:42:02 PM

Rank: Premium user

Groups: Premium Users, Member
Posts: 32
Location: Montreal
What happens if a PC has more than 1 network card?
Lansweeper
#12 Posted : Thursday, November 24, 2011 3:07:20 PM

Rank: Administration

Groups: Administration, Premium Users
Posts: 10,369
danielm wrote:
What happens if a PC has more than 1 network card?

They will both be listed on the computer's webpage. (Lansweeper cannot determine however if a network card is really Wake-on-LAN capable.)
Users browsing this topic
Guest
Untag as favorite
Forum Jump  
You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.

Contact: E-mail Lansweeper - Skype : Lansweeper
Copyright 2004 - 2011 © Hemoco bvba