WOL via SSH; ether-wake with hostname instead of MAC?

Discussion in 'Tomato Firmware' started by vexingv, Dec 21, 2008.

  1. vexingv

    vexingv LI Guru Member

    So I've recently discovered the joys of SSH and tunneling as I finally figured out how to get public/private keys working. Now, I would like to be able to WOL machines via SSH as I've encountered some firewalls that block 8080 preventing me from accessing the web gui.

    I understand that ether-wake can be used to WOL using the machine's MAC address as a parameter. However, is there a way to use the hostname as the parameter as I can't memorize the MAC address of machines on my network? The ether-wake help page states:
    How do I go about configuring/accessing the "ethers entry"? I have static DHCP entries set up in Tomato already. (*Be mindful, I'm very inexperienced with Linux and its shell...)

  2. quinezhu

    quinezhu Addicted to LI Member

    creat wol.sh (any filename you want) in /jffs on router:
    ether-wake [U]MAC address[/U]
    then, change its properties to excutable
    chmod +x wol.sh
    finally, add the following to Administration>Scripts>Init
    cat > /tmp/home/root/.profile <<EOF
      alias wol='/jffs/wol.sh'
    now restart the router and just type "wol" after SSH connected
  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice