LANTIME Difference Between Default and Interface Gateway
The LANTIME OS Web Interface allows the configuration of not only a Default Gateway but also interface-specific gateways for each individual virtual network interface:
The four examples below illustrate the differences between the default and interface gateways. These examples assume that you have a LANTIME with two physical interfaces: LAN0 (192.168.100.1/24) and LAN1 (192.168.101.1/24).
Example 1
The LANTIME only needs to serve NTP clients which are in the same local subnets (192.168.100.x and 192.168.101.x). The LANTIME is managed via HTTP/SSH from a PC which is also in one of these two subnets.
–> In this scenario, everything is in the same local subnets, so there is no need to configure
a gateway, as there is no need to communicate with remote clients.
Example 2
The LANTIME only needs to serve NTP clients which are in the same local subnets (192.168.100.x and 192.168.101.x), but the LANTIME needs to be managed by a remote PC with IP 172.27.50.50/16. The remote PC can be reached via gateway 192.168.100.254.
–> There are two possible solutions: you can configure 192.168.100.254 as the default gateway, OR you can configure it as the interface gateway for LAN0. In this scenario, it makes no difference whether you configure it as the default gateway or interface gateway. An interface gateway would be sufficient, because the SSH/HTTP session is initiated by the PC, the incoming HTTP request is passed through LAN0, and so the LANTIME sends the response to the interface gateway configured for LAN0.
Example 3
The LANTIME only needs to serve NTP clients which are in the same local subnets (192.168.100.x and 192.168.101.x). The LANTIME is managed via HTTP/SSH from a PC which is also in the same subnet. However, the LANTIME needs to talk to a remote NTP server with IP 172.27.50.60/16. This remote NTP server can be reached via gateway 192.168.100.254.
–> An interface gateway is not sufficient in this scenario as the LANTIME needs to initiate the session with the remote NTP server. Because the LANTIME has no way of knowing which interface it needs to send the NTP session request through, you will need to configure 192.168.100.254 as the default gateway. Alternatively, you could add a static route to the Extended Network Configuration submenu to have outbound NTP packets routed through the proper interface.
Example 4
The LANTIME needs to serve NTP clients which are in remote subnets (172.10.x.x and 172.11.x.x). The LANTIME is managed via HTTP/SSH from a PC which is also in one of these subnets. The subnet 172.10.x.x can be reached via gateway 192.168.100.254 (LAN0). The subnet 172.11.x.x can be reached via gateway 192.168.101.254 (LAN1).
–> In this scenario you can configure 192.168.100.254 as the interface gateway for LAN0 and 192.168.101.254 as the interface gateway for LAN1. While you could theoretically configure a default gateway, there is little point to doing so as the clients are behind two different gateways.
Conclusion
So, as a general rule of thumb, anything that needs the LANTIME to initiate a network session - such as querying external NTP servers, syslog servers, SNMP trap receivers, or authentication servers - requires a default gateway or static route if those servers are in a remote network, as the LANTIME needs to know which interface to send the session request through.
On the other hand, anything that needs the LANTIME to receive a session request, such as NTP requests from a remote client or HTTP/SSH requests from a remote PC, can be handled with an interface gateway, because the LANTIME knows which interface the request arrived through and can send the response back through the gateway configured for that interface.
— Manuel Schäfer manuel.schaefer@meinberg.de, last updated 2022-03-08