Tuning Route Cache

Dean E. Weimer dweimer at dweimer.net
Wed Jan 18 17:17:50 UTC 2017


I have been searching, but so far unsuccessfully found any hints. I have 
a situation that occurred with a FreeBSD server that is running 11.0 
that is in a DMZ with its default router directing traffic to other 
routers in the same subnet. we had one of those routers get swapped out 
last night. however the FreeBSD server still had the old router in its 
cache, and couldn't communicate with the remote sites.


Example
FreeBSD servers IP: 192.168.1.10
default gateway 192.168.1.1

route to 10.10.10.1/24 via 192.168.1.2
route to 10.10.20.1/24 via 192.168.1.3

the route to 10.10.20.1/24 was change to go through 192.168.1.4 around 
10 pm last night

as of 9am this morning the freebsd server still had cached route entries 
pointing the 10.10.20.1/24 devices through 192.168.1.3 instead of 
retrying the default route to receive the updated path.

I need to find a way to shorten this cache, I understand why its there 
to prevent repeated lookups, this doesn't happen all the time but I am 
thinking if I could change this cache length to a couple of hours this 
would have saved me a lot of trouble. As the routes would have cleared 
out over night and when users got back on the network in the morning 
everything would have been working.

Of course it would have also helped had the admin working with the 
provider informed me they were making a change, but somehow I don't 
think FreeBSD can solve that one for me.


-- 
Thanks,
    Dean E. Weimer
    http://www.dweimer.net/


More information about the freebsd-questions mailing list