From owner-freebsd-hackers@FreeBSD.ORG Sun Jul 6 22:45:26 2003 Return-Path: Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id A5A7537B401 for ; Sun, 6 Jul 2003 22:45:26 -0700 (PDT) Received: from cfcl.com (cpe-24-221-172-174.ca.sprintbbd.net [24.221.172.174]) by mx1.FreeBSD.org (Postfix) with ESMTP id 01CBD43FB1 for ; Sun, 6 Jul 2003 22:45:26 -0700 (PDT) (envelope-from rdm@cfcl.com) Received: from [192.168.254.205] ([192.168.254.205]) by cfcl.com (8.12.6/8.11.1) with ESMTP id h675lKj4068994 for ; Sun, 6 Jul 2003 22:47:21 -0700 (PDT) (envelope-from rdm@cfcl.com) Mime-Version: 1.0 Message-Id: X-Mailer: Eudora for Macintosh! Date: Sun, 6 Jul 2003 22:45:18 -0700 To: hackers@freebsd.org From: Rich Morin Content-Type: text/plain; charset="us-ascii" ; format="flowed" Subject: Adding second-level resolution to cron(8). X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 07 Jul 2003 05:45:26 -0000 I have a project for which I need a generalized time-based scheduling daemon. cron(8) is almost ideal, but it only has minute-level resolution. So, I'm thinking about modifying cron to add second-level resolution. Before I start, I thought I'd ask a few questions: * Has someone already done this? * Is it a Really Bad Idea for some reason? * Would anyone else be interested in having these modifications? The crontab(5) syntax is pretty well set in stone, but I think I see a way to extend it without causing any breakage. Specifically, I'd extend the format of the "minute" field, as: 1 minute 1 1,5 minutes 1 and 5 * any minute */5 any minute that is divisible by 5 1:2 second 2 of minute 1 1:2,5:10 second 2 of minute 1 and second 10 of minute 5 *:3 second 3 of any minute *:*/5 any second that is divisible by 5 Comments and suggestions (sans flamage) are solicited. -r -- email: rdm@cfcl.com; phone: +1 650-873-7841 http://www.cfcl.com/rdm - my home page, resume, etc. http://www.cfcl.com/Meta - The FreeBSD Browser, Meta Project, etc. http://www.ptf.com/dossier - Prime Time Freeware's DOSSIER series