FOR TIPS, gUIDES & TUTORIALS

subscribe to our Youtube

GO TO YOUTUBE

14455 questions

17168 answers

28195 comments

0 members

We are migrating to our new platform at https://community.teltonika.lt. Moving forward, you can continue discussions on this new platform. This current platform will be temporarily maintained for reference purposes.
0 votes
3,927 views 11 comments
by
Hi,

Is it possible to use a RUT955 to send WOL WakeOnLan packages to remotely turn on a PC on its LAN network?

I did not find it among the services, but maybe by script is it possible? Some examples?

Thanks!

bye bye

2 Answers

0 votes
by anonymous
Hi,

This function is not included in the standard FW version.

You could however take a look into this information:

https://oldwiki.archive.openwrt.org/doc/uci/etherwake
by
Thanks for reply, I saw the link, even if it is not very clear to me.

I hope that in some next version of the firmware will be present ;)

bye bye
0 votes
by anonymous

Hello,

Yes, sending WOL packets on RUT955 is possible, to configure it please follow this instruction:

Install etherwake on your RUT device (doesn’t work with RUT850). To install etherwake login into router via SSH and type:

opkg update

opkg install luci-app-wol

Edit etherwake config file

vi /etc/config/etherwake

Edited file should look similarly to this:

config 'etherwake' 'setup'

option 'pathes' '/usr/bin/etherwake /usr/bin/ether-wake'

option 'sudo' 'off'

option 'interface' 'eth0'

option 'broadcast' 'on'

config 'target'

option 'name' 'TeltonikaPC'

option 'mac' '00:22:33:44:55:66'

option 'password' 'AABBCCDDEEFF'

option 'wakeonboot' 'off'

To add more than one target use uci commands:

# uci add etherwake target

# uci set etherwake.@target[-1].name=example

# uci set etherwake.@target[-1].mac=11:22:33:44:55:66

# uci set etherwake.@target[-1].password=AABBCCDDEEFF

# uci set etherwake.@target[-1].wakeonboot=off

Target name can be anything, but is case sensitive.

Target MAC is mandatory

option ‘password’ can be left blank

After adding all your targets, configuration on router side is finished, now it is needed to configure target PC’s

Enable WoL in the BIOS

To enable WoL in the BIOS, enter the BIOS setup and look for something called "Wake up on PCI event", "Wake up on LAN" or similar. Change it so that it is enabled. ErP must be disabled. Save your settings and reboot.

For Ubuntu

To enable WoL in the NIC download ethtools package. For ubuntu use commands:

sudo apt-get install ethtool

Check if WoL is enabled in the NIC

sudo ethtool <NIC name eg.eth0 or enp1s0>

and look for

Wake-on: <letters>

If <letters> contains g and not d, then Magic Packet™ is enabled. However, if <letters> does contain d, WoL needs to be enabled by running the following command:

sudo ethtool -s <NIC> wol g

On most systems, issuing this command is required after each boot. To make this command run everytime PC boots we need to a script.

First create a text file named eg. wakeonlan at /etc/cron.d

sudo pico /etc/cron.d/wakeonlan

Paste this script into the file:

SHELL=/bin/sh

PATH=/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin

@reboot root /sbin/ethtool -s <your NIC name> wol g

To save and exit press ctrl+o, then enter and then ctrl+x

To test the setup, turn off device which you want to wake. Login into router via SSH and use command:

/etc/init.d/etherwake start <Target name> eg.

/etc/init.d/etherwake start TeltonikaPC

or

/usr/bin/etherwork -D -i "eth0" "device mac" eg.

/usr/bin/etherwake -D -i "eth0" "11:22:33:44:55:66"

If everything was configured properly, after using either of these commands target PC should start booting.

by anonymous

For Windows10

The computer must be in either Sleep or Hibernation mode for this to work.

Press Windows key + X to bring up the hidden quick access menu and select Device Manager.

Expand Network adapters in the device tree, select your Ethernet adapter, right-click it and then select Properties.

Then select the Power Management tab and check off all three boxes.

Next select the Advanced tab, scroll down in the Property box and select Wake on Magic Packet and ensure that it is enabled in the Value list box then click OK.

To test the setup, put the device which you want to wake to sleep/hibernation mode. Login into router via SSH and use command:

/etc/init.d/etherwake start <Target name> eg.

/etc/init.d/etherwake start TeltonikaPC

or

/usr/bin/etherwake -D -i "eth0" "device mac" eg.

/usr/bin/etherwake -D -i "eth0" "11:22:33:44:55:66"

If everything was configured properly, after using either of these commands target PC should wake from hibernation/sleep mode.

by
Hi,

thanks for the complete procedure, but maybe I have an initial problem... how do I get into SSH mode on the routers? Via ethernet does not answer (I use Putty on port 22), it is necessary to do it through the serial? The router is currently in another country...!

And even then to give the command is need to do it in SSH, then locally via serial?

Very thanks

bye bye
by
Hi,

Have you enabled "remote SSH access" on the router? System -> Administration -> Access Control
by
Yes it was already active, but thanks to your suggestion I noticed that it was on port 25 and not 22!

Now I have response, but using the login (admin) and password of the WebUI, it reply 'Access denied', is there a different password?

Thanks

bye bye
by anonymous
The login is not "admin" but "root" and password is the same as password you use to login to WebUI.
by

Thanks again, and sorry for the many questions ...

Ok, I had access and I'm trying to edit the file etherwake with vi editor, but I did not understand how I can save the changes, (I use windows) with Ctrl+ZZ   I exit the editor, but I do not save the changes, if I try to reopen it is like before :(

How should I proceed to make the changes? it's the first time I use vi

Very thanks!

bye bye

by anonymous
If you’re using “vi” text editor as suggested in the guide, press “i” to start editing file, and when you want to save and quit press “Esc” and write “:wq”
by

Ok, I managed to modify and made the tests ...

But it does not seem to work, the pc does not turn on again either by power off, nor by sleep mode, yet the packages I think are sent, this is the ScreenShot

I have tested with Target name and with MAC, but nothing

Any idea?

Thanks again

by anonymous
Hello,
it is possible whit SMS Utilities UCI API to send a Magic Packet with EtherWake or other?
by anonymous
Hi,

Is it possible to install this package on RU240?