[ previous ] [ next ] [ threads ]
 From:  JR <tiresias at gmail dot com>
 To:  "Chris Bagnall" <lists at minotaur dot cc>
 Cc:  m0n0wall at lists dot m0n0 dot ch
 Subject:  Re: [m0n0wall] ALIX system time
 Date:  Sun, 17 Feb 2008 05:34:59 -0500
On Feb 16, 2008 2:10 PM, Chris Bagnall <lists at minotaur dot cc> wrote:
> I don't think it's that, because it seems to happen randomly, not every time. I think that
sometimes NTP comes up before the net connection, and then fails because uk.pool.ntp.org (in my
case, yours is obviously different) isn't resolvable.

Having looked at the scripts, I don't think this is the case. m0n0wall
restarts msntp once per second if it exits, and if it cannot resolve
the hostname it is given, it exits immediately. I just tested with a
new ALIX router and a fresh 1.3b9 default config. If I boot up the
router with the WAN port disconnected, the clock is set to 2000-01-01
00:00, but apparently the instant I connect the WAN cable, the clock
gets set to the current time.

That eliminates your theory and mine, so as for the problem with the
VPN routers I have in production, I can only guess that the IP
resolved for 0.north-america.pool.ntp.org by these routers at that
time was a non-functioning ntp server. I've learned that msntp will
not exit if it is given (or resolves to) an IP where there no ntp
server is responding. It seems to wait indefinitely on a broken or
unreachable time server and it is not possible to specify a timeout.

If this is true, it doesn't help my situation at all. The only
work-around I can imagine is to run my own ntp server on the internet
and make sure it is always online and reachable from everywhere, which
is pretty unrealistic.