Page 1 of 1

NTP server on second NIC with no gateway ?

Posted: Sat Jun 06, 2020 6:53 pm
by Sparks
If you run an NTP time server on a secondary NIC, how can it get updates from the WWW without a gateway address for NIC2

NIC1 - Primary network 192.168.1.xxx - gateway 192.168.1.254
NIC2 - Camera network 192.168.10.xxx - no gateway defined

I am using the Meinburg server and recently added a second NIC and moved all the cameras to the 192.168.10.xxx network. But I am unclear as to how the NTP server can get updates if it is on an isolated network. Wouldn't a gateway on the 10.xxx net defeat the purpose of isolation ?

Thanks for your input !

Re: NTP server on second NIC with no gateway ?

Posted: Sun Jun 07, 2020 3:37 am
by MikeBwca
bump

Re: NTP server on second NIC with no gateway ?

Posted: Sun Jun 07, 2020 8:12 am
by TimG
Hi, in my case, I had two NICs on my BI5 pc, and ran the NTP time server on the same pc which was able to update itself via the primary NIC and the internet. The cameras on the second NIC were able to pick it up (except the Foscam) using the IP address of the second NIC with port 123.
This worked well with the Dahua and Ertech cams. They were were not able to update via the www time servers.
Note that I used static IP addresses for all devices on the second NIC. There was no router.

Re: NTP server on second NIC with no gateway ?

Posted: Mon Jun 08, 2020 12:34 pm
by Matts1984
I'm not particularly familiar with Meinburg but the way it SHOULD work is that your server simply has one routing table. If the server needs to talk to something on 192.168.10.x, the routing table says to use NIC2. If it wants to talk to 192.168.1.x it uses NIC1. If it wants to talk to time.nist.gov (or something) - the routing table says to send that traffic to 192.168.1.254 which is on NIC1. It shouldn't make a difference.

That being said, I have seen SOME software be bound to a particular interface only. In that case it's really a software thing and a bit more complicated. In the event that is an issue, perhaps the software can simply be bound to both NICs?

Re: NTP server on second NIC with no gateway ?

Posted: Tue Jun 09, 2020 3:21 am
by Sparks
Thanks for the help. I think Matts1984 is correct. There are no logs that I could find but I've run the the NTPStatus batch file and it does appear to be making a WWW connection even though the config file has the servers address set to an interface with no gateway.

Checking current status of NTP service with ntpq -p
remote refid st t when poll reach delay offset jitter
==============================================================================
Node0 .STEP. 16 u - 32 0 0.000 0.000 0.000
*ns542832.ip-158 213.251.128.249 2 u 64 64 377 57.235 2.761 0.917
+rocinante.baxte 206.108.0.131 2 u 53 64 377 23.088 3.124 1.990
-time.cloudflare 10.153.8.4 3 u 9 64 377 17.197 -0.703 1.065
+europa.netbunke 209.51.161.238 2 u 8 64 377 71.465 2.266 0.807
-2607:fa18:3:88: 206.108.0.131 2 u 43 64 377 26.100 6.435 0.952
(Auto-Refresh every 10s --- CTRL+C to Cancel)


As an aside, after reading a thread on this site I am considering making a move to the Windows built in NTP server.