From owner-freebsd-hackers Sun Jan 14 13:32:21 2001 Delivered-To: freebsd-hackers@freebsd.org Received: from smtp02.teb1.iconnet.net (smtp02.teb1.iconnet.net [209.3.218.43]) by hub.freebsd.org (Postfix) with ESMTP id 1872D37B400 for ; Sun, 14 Jan 2001 13:32:01 -0800 (PST) Received: from bellatlantic.net (client-151-198-117-43.nnj.dialup.bellatlantic.net [151.198.117.43]) by smtp02.teb1.iconnet.net (8.9.1/8.9.1) with ESMTP id QAA01180; Sun, 14 Jan 2001 16:31:44 -0500 (EST) Message-ID: <3A621ABF.FA2C6432@bellatlantic.net> Date: Sun, 14 Jan 2001 16:31:43 -0500 From: Sergey Babkin X-Mailer: Mozilla 4.7 [en] (X11; U; FreeBSD 4.0-19990626-CURRENT i386) X-Accept-Language: en, ru MIME-Version: 1.0 To: John Gregor Cc: Gerhard.Sittig@gmx.net, leifn@neland.dk, freebsd-hackers@FreeBSD.ORG, gjb@gbch.net Subject: Re: how to test out cron.c changes? (was: cvs commit: src/etc crontab) References: <200101140244.f0E2i3518278@vieo.com> Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG John Gregor wrote: > > What would happen if the definitions of the hour and minute fields > were subtly changed to mean "elapsed wall-clock time since local > midnight"? Then, the DST conversion is no longer ambiguous. "Two > hours since local midnight" only happens once regardless. On days > where the clocks change, most scripts would wind up running an hour > ahead or behind their usual time, but hey, so are many of the people > :-). There would also have to be an entry in the BUGS section noting > that some days have 23 or 25 hours, which is accurate. I believe that the handling of DST change in cron must be fixed. Practically every commercial Unix (except the very retarded ones) does that and that's something the sysadmins normally expect. I'll probably look if I can fix it. The logic I plan to implement is (this is a quote from somewhere else but it describes my intentions): Now the jobs run as intuitively expected. If a job falls into time interval that disappears during switch from standard time (ST) to daylight saving time (DST) or is duplicated during the reverse switch, then it's handled in one of 2 ways. The jobs that run every hour work as before, they skip the skipped hour or run in the added hour as usual. But the jobs that run less frequently are executed exactly once, they are not skipped nor executed twice (unless cron is restarted or the user's crontab is changed during such a time interval). -SB To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message