Remote Wake On LAN via Port Forwarding

Hi
How wol from internet the pc in lan.

How do this, like in DD-WRT

Remote Wake On LAN via Port Forwarding

https://wiki.dd-wrt.com/wiki/index.php/Wake-on-LAN_(tutorial)

might still be relevant, even if old

read the comments too

1 Like

Thanks
How add ARP
arp -i br0 -s 192.168.1.254 FF:FF:FF:FF:FF:FF
on Open Wrt

root@OpenWrt:~# ip neigh add 192.168.1.254 lladdr ff:ff:ff:ff:ff:ff nud permanent dev br-lan
ip: invalid argument 'add' to 'ip'

there's a reason my post said what it said ...

I cant add ARP entry by ip neigh add. Please help

What the way? is it right?

uci add network neighbor
uci set network.@neighbor[-1].interface='br-lan'
uci set network.@neighbor[-1].ipaddr='192.168.1.254' #Server IP
uci set network.@neighbor[-1].mac='ff:ff:ff:ff:ff:ff' #Server MAC
uci commit network
/etc/init.d/network restart.

interface='br-lan' ?

Ok, let's try it one more time

read the comments too

no idea, trial and error.

In comment writes ip neight add. But i cant do this

opkg install ip-full

there are also other suggestions, not requiring ip, like I said, read the comments ...

What do you mean?

So many years have passed, And there is not a single intelligible tutorial in the wiki on how to provide wol from external ip addresses. You have to look for the devil knows where. I don't want to install a whole updated ip distribution just for one command. Is there really no guru here who would suggest how to prescribe arp in the best way.

After add ip neigh add 192.168.1.254 lladdr ff:ff:ff:ff:ff:ff nud permanent dev br-lan to /etc/rc.local, after reboot arp not changed absolutely
I spent a whole day and achieved nothing. Why no one can clearly say anything is unknown ...
What money to pay you? So let's get your rates.

There is actually very simple way to provide WOL pointed at your LAN form the wan side which is secure and far less complicated than trying to setup a listener on the wan to trigger the magic packet towards the lan. This is what I have setup, personally... works well:

  • Configure a VPN endpoint on your router (I'd recommend Wireguard)
  • Setup the other VPN endpoint on your phone, computer, remote OpenWrt router, etc.
  • Install LuCI-app-WOL
  • Connect to the VPN, navigate to the WOL page on your router and select the host you want to wake.
1 Like

Ok, Mini Wiki
Tested on:

D-Link DIR825B1
OpenWrt 22.03.3 r20028-43d71ad93e / LuCI openwrt-22.03 branch git-22.361.69894-438c598

Router must have public IP.
Step 1. - Create a port forward rule on the Web Interface


Step 2. - Add a static ARP entry
Option a: (desirable)

uci add network neighbor
uci set network.@neighbor[-1].interface='lan'
uci set network.@neighbor[-1].ipaddr='192.168.1.254' #Server IP
uci set network.@neighbor[-1].mac='ff:ff:ff:ff:ff:ff' #Server MAC
uci commit network
/etc/init.d/network restart

Option b:
In ash:
opkg install ip-tiny (in case of errors)
Put the commands

sleep 30
ip neigh replace 192.168.1.254 lladdr ff:ff:ff:ff:ff:ff nud permanent dev br-lan

to /etc/rc.local
Restart the router

=======
After that:
In ash:
arp or cat /proc/net/arp - because it just alias, not binary
The part of output must be something like that:

192.168.1.254    0x1         0x6         ff:ff:ff:ff:ff:ff     *        br-lan

=====
Client setup:
Host Name: DynDNS name or router white ip
Subnet Mask: 255.255.255.255
MAC Address: WOL computer MAC address, not the OPEN-WRT MAC.
port 9

This topic was automatically closed 10 days after the last reply. New replies are no longer allowed.