From owner-freebsd-questions Thu Dec 26 9:23:15 2002 Delivered-To: freebsd-questions@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 8A55937B401 for ; Thu, 26 Dec 2002 09:23:14 -0800 (PST) Received: from fep02-mail.bloor.is.net.cable.rogers.com (fep02-mail.bloor.is.net.cable.rogers.com [66.185.86.72]) by mx1.FreeBSD.org (Postfix) with ESMTP id 89E0243ED8 for ; Thu, 26 Dec 2002 09:23:13 -0800 (PST) (envelope-from mj001@rogers.com) Received: from rogers.com ([24.101.253.54]) by fep02-mail.bloor.is.net.cable.rogers.com (InterMail vM.5.01.05.06 201-253-122-126-106-20020509) with ESMTP id <20021226172239.UVJW513731.fep02-mail.bloor.is.net.cable.rogers.com@rogers.com>; Thu, 26 Dec 2002 12:22:39 -0500 Message-ID: <3E0B3AFB.4050607@rogers.com> Date: Thu, 26 Dec 2002 12:23:07 -0500 From: Mike Jeays User-Agent: Mozilla/5.0 (X11; U; FreeBSD i386; en-US; rv:1.0.1) Gecko/20021005 X-Accept-Language: en-us, en MIME-Version: 1.0 To: Kirk Bailey Cc: FreeBSD-Questions@FreeBSD.ORG Subject: Re: cron/crontab befuddlement References: <3E0B2984.7020405@netzero.net> Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit X-Authentication-Info: Submitted using SMTP AUTH PLAIN at fep02-mail.bloor.is.net.cable.rogers.com from [24.101.253.54] using ID at Thu, 26 Dec 2002 12:22:39 -0500 Sender: owner-freebsd-questions@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG Kirk Bailey wrote: > ok, I read man cron and man crontab, and it's as clear as mud. > Anyplace I can read more and maybe make the light dawn on this useful > feature? OR, would anyone care to explain more? > Basically, you create a file where each line is a command to be executed on a given schedule. The line looks like this (first line is a descriptive comment): #minute hour mday month wday command 15 5 * * * /home/mike/bin/FindAll This says to run the command /home/mike/bin/FindAll at 15 minutes past 5, every day. The asterisks mean "ignore this field", in effect. Wday is the day of the week (I think Sunday=0, Monday 1 etc, but check) Month is the month, either 1-12 or a three-letter abbreviation, such as "Oct" Mday is the day of the month. So to run something at 11:15 on October 1st, you would say: 15 11 1 Oct * /home/me/mycommand. You must create this file by running "crontab -e", which will put you into your favourite editor. You can examine the file with "crontab -l" That's it, in a nutshell - details are from memory, so please check! To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message