From owner-freebsd-questions Thu Dec 26 10:11: 7 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 0CD5937B401 for ; Thu, 26 Dec 2002 10:11:05 -0800 (PST) Received: from sage-one.net (adsl-65-71-135-137.dsl.crchtx.swbell.net [65.71.135.137]) by mx1.FreeBSD.org (Postfix) with ESMTP id DC54043EB2 for ; Thu, 26 Dec 2002 10:11:03 -0800 (PST) (envelope-from jackstone@sage-one.net) Received: from sagea (sagea [192.168.0.3]) by sage-one.net (8.11.6/8.11.6) with SMTP id gBQIAxK01589; Thu, 26 Dec 2002 12:10:59 -0600 (CST) (envelope-from jackstone@sage-one.net) Message-Id: <3.0.5.32.20021226121057.0125d188@mail.sage-one.net> X-Sender: jackstone@mail.sage-one.net X-Mailer: QUALCOMM Windows Eudora Pro Version 3.0.5 (32) Date: Thu, 26 Dec 2002 12:10:57 -0600 To: Kirk Bailey , Mike Jeays From: "Jack L. Stone" Subject: Re: cron/crontab befuddlement Cc: FreeBSD-Questions@FreeBSD.ORG In-Reply-To: <3E0B3EAC.8070105@netzero.net> References: <3E0B2984.7020405@netzero.net> <3E0B3AFB.4050607@rogers.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" 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 At 12:38 PM 12.26.2002 -0500, Kirk Bailey wrote: >ok, this is making sense. Do you recall how to configure the FreeBSD so it >will define a preferred editor in the environment? As of now, it runs the >default of vi, which I dispise,. I have ee and pico in my box, and >generally run pico. > > > >Mike Jeays wrote: >> 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! >> No, you don't need to run "crontab -e" and can use Pico as follows (also use the setenv to keep the editor as Pico): Within each $HOME, just create a regular file using your preferred Pico editor and name the file "cronfile" or whatever and set up the same fields. You can copy the file from: /usr/share/examples/etc/crontab ...to the various user homes. After edits for commands, then just run "crontab cronfile" within each user being setup. running "crontab -l" will confirm if the file is active according to your setup. Best regards, Jack L. Stone, Administrator SageOne Net http://www.sage-one.net jackstone@sage-one.net To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message