Re: Cronjob every hour
On Mon, May 05, 2003 at 10:15:25PM +0200, Willem-Jan Meijer wrote:
> > On Mon, 5 May 2003 12:28:14 +0200
> > "Willem-Jan Meijer" <meyer3@chello.nl> wrote:
> >> I'm running webalizer for my website statistics. They are modified
> >> every day, but I want it to run every hour In /etc/cron.d/ I added a
^^^^^^^^^^^^
> >> file named webalizer and put the line
> >>
> >> 15 * * * * nice /etc/cron.daily/webalizer
> >>
> >> In it, but when it's e.g. 12:15 nothing happens.
> >>
> >> What do I have to setup, so that my statistics are modified every
> >> hour?
Files in /etc/cron.d need to include the user to run the job as. As
written, your /etc/cron.d/webalizer is attempting to run
/etc/cron.daily/webalizer as a user named "nice". You probably don't
have a user by that name, so it fails.
Change it it
15 * * * * root nice /etc/cron.daily/webalizer
and it should behave as you intended. (Although running webalizer as
a non-root user with read access to the logs and write access to the
stats directory would be better...)
--
The freedoms that we enjoy presently are the most important victories of the
White Hats over the past several millennia, and it is vitally important that
we don't give them up now, only because we are frightened.
- Eolake Stobblehouse (http://stobblehouse.com/text/battle.html)
Reply to: