Changeset 2231


Ignore:
Timestamp:
Dec 6, 2012, 2:43:01 PM (6 years ago)
Author:
matthijs
Message:

luci-wol: Send etherwake packets to br-lan.

Before, no interface name was passed to etherwake, making it default to
eth0. On 2.0n, this seemed to work (presumably this would send the
packet without a VLAN tag to the embedded switch, which apparently sent
the packet to the LAN ports). On 2.0g, the embedded switch behaved
differently, causing the packet not to be sent out through the LAN port.

By explicitly sending the packet to br-lan, it will be sent out through
the correct ports, making this plugin work on 2.0g as well.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/luci/applications/luci-wol/luasrc/model/cbi/wol.lua

    r2228 r2231  
    55function do_power_on(mac)
    66        os.execute("logger -- Sending WOL packet to %q" % {mac})
    7         os.execute("etherwake %q 2>&1 | logger -t etherwake" % {mac})
     7        os.execute("etherwake -i br-lan %q 2>&1 | logger -t etherwake" % {mac})
    88end
    99
Note: See TracChangeset for help on using the changeset viewer.