ARP TABLE Refresh time for Wake On Lan
-
In the list of machines that I set to wake on lan the machines are marked as turned on even if I just turned them off.
From the tests I did, about 20 minutes pass before the status is updated.I've read that it depends on the ARP table being updated.
Is it possible to change the ARP table update time?
How much is this value?
-
Yes 15-20mins is the expected timeout for ARP.
You can set
net.link.ether.inet.max_age
to something lower. It's 1200s by default.Steve
-
@Unoptanio said in ARP TABLE Refresh time for Wake On Lan:
Is it possible to change the ARP table update time?
While yes it is possible to change this, normally if you want to WOL, its best to have a static arp.. So pfsense always knows what mac to send the WOL too even if the device is "off" and not sending traffic or answering arps..
Pretty sure when you create the wol entry, pfsense stores the mac to send too, so static arp entry really isn't needed.
So you just want to know from the dhcp leases what devices are not currently active and you want this to be lower so you you see inactive devices sooner? Keep in mind if you lower the arp cache time, you will be more likely to show stuff offline when its not.. That list is only showing devices as offline that pfsense has not seen traffic from.. So if you say sent it to 60 seconds for example, and box hasn't sent anything in say 61 seconds the device would show offline, when it really isn't
Keep in mind that the ttl for the cache item doesn't update every time there is traffic, so if the cache expires - and no traffic seen after it expired you would show offline..
See for example I am actively talking to pfsense from 192.168.9.100, and the ttl is counting down
[23.09.1-RELEASE][admin@sg4860.home.arpa]/root: arp 192.168.9.100 i9-win.home.arpa (192.168.9.100) at b0:4f:13:0b:fd:16 on igb0 expires in 401 seconds [ethernet] [23.09.1-RELEASE][admin@sg4860.home.arpa]/root: arp 192.168.9.100 i9-win.home.arpa (192.168.9.100) at b0:4f:13:0b:fd:16 on igb0 expires in 399 seconds [ethernet] [23.09.1-RELEASE][admin@sg4860.home.arpa]/root: arp 192.168.9.100 i9-win.home.arpa (192.168.9.100) at b0:4f:13:0b:fd:16 on igb0 expires in 398 seconds [ethernet] [23.09.1-RELEASE][admin@sg4860.home.arpa]/root: arp 192.168.9.100 i9-win.home.arpa (192.168.9.100) at b0:4f:13:0b:fd:16 on igb0 expires in 397 seconds [ethernet] [23.09.1-RELEASE][admin@sg4860.home.arpa]/root: arp 192.168.9.100 i9-win.home.arpa (192.168.9.100) at b0:4f:13:0b:fd:16 on igb0 expires in 396 seconds [ethernet] [23.09.1-RELEASE][admin@sg4860.home.arpa]/root: arp 192.168.9.100 i9-win.home.arpa (192.168.9.100) at b0:4f:13:0b:fd:16 on igb0 expires in 386 seconds [ethernet] [23.09.1-RELEASE][admin@sg4860.home.arpa]/root:
Before you go messing with the arp cache time, I would be sure its going to do what you think its going to do for your use case.
Changing it might not have the effect your looking for, and would just increase the number of arps that pfsense needs to send.
-
I found this old post from the year 2009.
https://forum.netgate.com/post/188005To make the command permanent:
sysctl net.link.ether.inet.max_age=600
just add it in the /etc/sysctl.conf file?
600ms=10minutes
Does this still apply to the latest versions of pfsense?
Or should I add the constant in this list?
-
@Unoptanio said in ARP TABLE Refresh time for Wake On Lan:
just add it in the /etc/sysctl.conf file?
Nope, pfSense doesn't use that. The system tunables table replaces it so add it there if you need to.