From owner-freebsd-questions Fri Feb 23 21: 6:11 2001 Delivered-To: freebsd-questions@freebsd.org Received: from xena.gsicomp.on.ca (cr677933-a.ktchnr1.on.wave.home.com [24.43.230.149]) by hub.freebsd.org (Postfix) with ESMTP id D57F837B491 for ; Fri, 23 Feb 2001 21:06:06 -0800 (PST) (envelope-from matt@xena.gsicomp.on.ca) Received: from localhost (matt@localhost) by xena.gsicomp.on.ca (8.11.1/8.9.3) with ESMTP id f1O54Fl02227 for ; Sat, 24 Feb 2001 00:04:16 -0500 (EST) (envelope-from matt@xena.gsicomp.on.ca) Date: Sat, 24 Feb 2001 00:04:15 -0500 (EST) From: Matthew Emmerton Cc: freebsd-questions@FreeBSD.ORG Subject: Re: crontab for root In-Reply-To: <20010223205013.U87083@dell.dannyland.org> Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: owner-freebsd-questions@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG On Fri, 23 Feb 2001, dannyman wrote: > On Fri, Feb 23, 2001 at 06:52:34PM -0800, Kalai Kalaiarasi wrote: > > Hi, > > > > Does anyone knows how to set crontab for root? I am > > able to set the crontab for normal user and it's > > working fine. When i try set crontab for root, the > > shell script doesnt seem to run. Is there anything > > else i need to do?? Please do help me.... I've seen a lot of posts on this lately, and I'm wondering if I'm missing something. To edit root's crontab, I usually just log in as root (from the console, or via ssh from my workstation) and just do a 'crontab -e'. Edit, save, and all is well. It's worked fine for me (runs over 15 scripts nightly for backups, log archival, web stats processing, cvsup, etc) on a bunch of my boxes for over a year and a half, along with the standard root cron stuff. This means that I have *two* root crontabs - the standard one in /etc/crontab, and my custom one in /var/cron/tabs/root. Is there anything wrong with this type of setup? More importantly, why would you add 'custom' mods to /etc/crontab when you can use 'crontab -e' to update the one in /var/cron/tabs/root? (The advantage I've seen is that when you upgrade, all of your custom mods to root's crontab won't be blown away if you accidentally install the /usr/src version of /etc/crontab.) -- Matt Emmerton To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message