Except in a simple star network static routes are needed rather than only a single gateway. Consider:
/---192.168.1.1xx [clients X]
[Public Internet upstream] 99.99.99.1 ----------- 99.99.99.50 [eth0 router X eth1] 192.168.1.1 -----*A*---- 192.168.1.254 [router Y eth0]
[clients Y] 192.168.2.1xx ------------- 192.168.2.1 [router Y eth1]
If the NTP-250 is switched in at point A, with gateway 192.168.1.254 it can reply to requests from [clients X] and [clients Y] but it cannot reach the Internet. If it has gateway 192.168.1.1 it can reach the Internet, but cannot reply to [clients Y] on 192.168.2.x.
There is a workaround. [Router Y[ could SNAT all NTP requests coming from [clients Y] so they appear to be coming from 192.168.1.254 and in that case the NTP-250 replies to 192.168.1.254, which is passed back to the client by [Router Y]. However this adds overhead and delay which is particularly undesirable for precision timekeeping.
A simple syntax could be within conf network :
ip4 route destination-IP/mask gateway-IP
e.g. ip4 route 192.168.2.0/24 192.168.1.254
An even better alternative would be to allow general Linux commands to the NTP-250 CLI:
exec arbitrary-linux-command-string
e.g. exec ip route add 192.168.2.0/24 metric 100 nexthop via 192.168.1.254
Except in a simple star network static routes are needed rather than only a single gateway. Consider:
If the NTP-250 is switched in at point A, with gateway 192.168.1.254 it can reply to requests from [clients X] and [clients Y] but it cannot reach the Internet. If it has gateway 192.168.1.1 it can reach the Internet, but cannot reply to [clients Y] on 192.168.2.x.
There is a workaround. [Router Y[ could SNAT all NTP requests coming from [clients Y] so they appear to be coming from 192.168.1.254 and in that case the NTP-250 replies to 192.168.1.254, which is passed back to the client by [Router Y]. However this adds overhead and delay which is particularly undesirable for precision timekeeping.
A simple syntax could be within
conf network:ip4 route destination-IP/mask gateway-IPe.g.
ip4 route 192.168.2.0/24 192.168.1.254An even better alternative would be to allow general Linux commands to the NTP-250 CLI:
exec arbitrary-linux-command-stringe.g.
exec ip route add 192.168.2.0/24 metric 100 nexthop via 192.168.1.254