From owner-freebsd-hackers Tue Apr 7 03:01:22 1998 Return-Path: Received: (from majordom@localhost) by hub.freebsd.org (8.8.8/8.8.8) id DAA28438 for freebsd-hackers-outgoing; Tue, 7 Apr 1998 03:01:22 -0700 (PDT) (envelope-from owner-freebsd-hackers@FreeBSD.ORG) Received: from dt050n33.san.rr.com (@dt050n33.san.rr.com [204.210.31.51]) by hub.freebsd.org (8.8.8/8.8.8) with ESMTP id DAA28433 for ; Tue, 7 Apr 1998 03:01:20 -0700 (PDT) (envelope-from Studded@san.rr.com) Received: from san.rr.com (Studded@localhost [127.0.0.1]) by dt050n33.san.rr.com (8.8.8/8.8.8) with ESMTP id DAA08149; Tue, 7 Apr 1998 03:01:05 -0700 (PDT) (envelope-from Studded@san.rr.com) Message-ID: <3529F961.31919220@san.rr.com> Date: Tue, 07 Apr 1998 03:01:05 -0700 From: Studded Organization: Triborough Bridge & Tunnel Authority X-Mailer: Mozilla 4.05 [en] (X11; I; FreeBSD 2.2.6-STABLE-0325 i386) MIME-Version: 1.0 To: Terry Lambert CC: Archie Cobbs , hackers@FreeBSD.ORG Subject: Re: Daylight Savings Time - bug References: <199804070803.BAA25988@usr09.primenet.com> Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG Terry Lambert wrote: > How does cron deal with time adjustments? Like so much else in the unix world, it expects the operator to be smarter than it is. :) There are a couple of us who are working on some proposals for Paul Vixie along the following lines. 15 2S * * * /job Would run the job in standard time all year round, ignoring DST 15 2U * * * /job Runs the job in UTC time. Without modification the job would happen or not happen the same way it does now. I would like to add a warning for the user if they schedule a job that happens during the magic hour. This would probably require a text file somewhere, probably in /var/cron. The implementation would be something like: 1. cron starts up, polls the system to determine the dates and hour of the DST change and compares the value in the file (if any) to the answer it received and writes it as necessary. 2. User foo edits their crontab file and adds a job that is scheduled during the magic hour. While crontab writes out the tab it checks for this condition and warns the user that they've scheduled a job during this time period and they gives them options, something like: Your job "15 2 * * * /usr/foo" is scheduled during the hour of the Daylight Savings Time transition in the Pacific time zone where this machine is located. If this might result in a scheduling problem please read the "Sceduling Options" section of the man page for crontab(5). 3. cron saves the fact that it's warned the user about this job to the file mentioned above, perhaps using an MD5 checksum of the job for security? 4. When user foo does subsequent updates to their crontab as long as they don't change that job they won't get warned about that job. Comments? Doug -- *** Chief Operations Officer, DALnet IRC network *** *** Proud operator, designer and maintainer of the world's largest *** Internet Relay Chat server. 5,328 clients and still growing. *** Try spider.dal.net on ports 6662-4 (Powered by FreeBSD) To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message