Re: cron job mergelog failure
- From: Noah Meyerhans <noahm@xxxxxxxxxx>
- Date: Wed, 8 Feb 2012 08:35:44 -0800
On Wed, Feb 08, 2012 at 10:57:54AM -0500, Tony Baldwin wrote:
0 1 * * * mergelog /var/log/apache2/access.log [...]
Every day I get an e-mail telling me this failed.
Now, I can go in and to this manually,
Why can't cron do it without my intervention?
What reason does the email give for the failure?
Chris
mv: cannot stat `/var/log/apache2/MY.log': No such file or directory
Clearly not merging logs and creating the MY.log file.
I will try with the fully path and see happens tonight.
Your first cron job:
0 1 * * * mergelog /var/log/apache2/access.log /var/log/apache2/other_vhosts_access.log /var/log/apache2/my.log > MY.log
This does not run with /var/log/apache2/ as $PWD, so MY.log won't be
created in that directory. Try being explicit about the path to MY.log,
e.g. /var/log/apache2/MY.log
noah
Attachment:
signature.asc
Description: Digital signature
- Follow-Ups:
- Re: cron job mergelog failure
- From: Tony Baldwin
- Re: cron job mergelog failure
- References:
- cron job mergelog failure
- From: Tony Baldwin
- Re: cron job mergelog failure
- From: Chris Davies
- Re: cron job mergelog failure
- From: Tony Baldwin
- cron job mergelog failure
- Prev by Date: Re: DHCPOFFER lost in transit :-)
- Next by Date: Re: [OT] webhttrack fails
- Previous by thread: Re: cron job mergelog failure
- Next by thread: Re: cron job mergelog failure
- Index(es):
Relevant Pages
|