Re: [Dovecot] Time just moved backwards error even with ntpd
Hi!
Am Samstag, 19. Januar 2008 schrieb Luigi Rosa:
How about first starting ntpd, forcing a time-update using ntpdate even before starting ntpd, and delaying the dovecot start until after the time has been adjusted? The problem is tha you cannot tell when the time is adjusted because it take some time to the ntp protocol to synchronize.
That's why I suggested to use ntpdate to force the correct time to be set before ntpd even starts and the ntp init script returns.
Admittedly, this won't work if you have no network connectivity during boot up, but if you have, this paticular problem is most likely solved.
ntpdate optionally can be given a timeout value and indicates success or failure via its return code so that a calling script might initiate appropriate measures.
Greetings,
Gunter
--
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
"You're dead," he said. Keli waited. She couldn't think of any suitable
reply. "I'm not" lacked a certain style, while "Is it serious?" seemed
somehow too frivolous. -- Princess Keli in trouble
(Terry Pratchett, Mort)
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+PGP-verschlüsselte Mails bevorzugt! +
Gunter Ohrner said the following on 19/01/08 16:51:
That's why I suggested to use ntpdate to force the correct time to be set before ntpd even starts and the ntp init script returns. Admittedly, this won't work if you have no network connectivity during boot up, but if you have, this paticular problem is most likely solved.
I don't remember if there already is an ntpdat on that particular machine, but many ntpd startup script have an ntpdate entry. I'll check.
But I don't think that this is the point.
According to Dovecot Wiki, "If all else fails, you can just go and remove the error checking code from src/lib/ioloop.c. It's unlikely that anything will break badly, but you might get some errors logged once in a while."
On one hand we have Dovecot that kill itself until someone kicks it back on, on the other hand we have just some errors on the logfile.
Well, IMHO at least there could be a configuration parameter that allows me to choose between a service that kills itself and some errors on a logfile and maybe a temporary service failure.
Each SysAdmin could weight the consequences and choose the option he/she thinks is more appropriate to his/her server.
Ciao, luigi
-- / +--[Luigi Rosa]-- \
Success is 99% failure. --Soichiro Honda
On 1/19/2008 Luigi Rosa wrote:
On one hand we have Dovecot that kill itself until someone kicks it back on, on the other hand we have just some errors on the logfile.
Well, IMHO at least there could be a configuration parameter that allows me to choose between a service that kills itself and some errors on a logfile and maybe a temporary service failure.
Each SysAdmin could weight the consequences and choose the option he/she thinks is more appropriate to his/her server.
Accurate time is CRITICAL for a mail server (and most any other server as well).
I think the current behavior is reasonable. Fix the actual problem (server time being incorrect at boot time), and this is not an issue.
On Sat, Jan 19, 2008 at 11:07:58AM -0500, Charles Marcus wrote:
On 1/19/2008 Luigi Rosa wrote:
On one hand we have Dovecot that kill itself until someone kicks it back on, on the other hand we have just some errors on the logfile.
Well, IMHO at least there could be a configuration parameter that allows me to choose between a service that kills itself and some errors on a logfile and maybe a temporary service failure.
Each SysAdmin could weight the consequences and choose the option he/she thinks is more appropriate to his/her server.
Accurate time is CRITICAL for a mail server (and most any other server as well).
I think the current behavior is reasonable. Fix the actual problem (server time being incorrect at boot time), and this is not an issue.
Even without this problem, it may be wise to add a script to check often if dovecot is running, and start it if it is not. That way your downtime caused by this issue will be minimal. and/or add more servers so users won't notice any downtime except possibly being disconnected once.
participants (4)
-
Adam McDougall
-
Charles Marcus
-
Gunter Ohrner
-
Luigi Rosa