[ubuntu-za] crontab

Scharnick, Walter WScharnick at fnb.co.za
Sun Feb 8 16:59:51 GMT 2009


I don't specify a user. I quess when I do crontab -e that it will run as
myself. See below...
Walter at uu~/runfive$ crontab -l
0,5,10,15,20,25,30,35,40,45,50,55 * * * 1,2,3,4,5,6,7 cd / &&
/var/www/mrtg/runfive/hawk.php



-----Original Message-----
From: ubuntu-za-bounces at lists.ubuntu.com
[mailto:ubuntu-za-bounces at lists.ubuntu.com] On Behalf Of Stefan Lesicnik
Sent: Sunday, February 08, 2009 6:51 PM
To: Ubuntu South African Local Community
Subject: Re: [ubuntu-za] crontab

Heys,

Permission problem. Not with your script, but rather with the file
trying to open or write to - n_tunnel_UpDownStates.dat

Who is the script running as? Does that user have access to write to
that file?

Stefan Lesicnik

Linux System Dynamics

mail: stefan at lsd.co.za
tel : +27 (0)86 111 6094
cell: +27 (0)84 951 9321
gpg : http://www.lsd.co.za/files/keys/stefan.gpg.pub




On Sun, Feb 8, 2009 at 6:29 PM, Scharnick, Walter <WScharnick at fnb.co.za>
wrote:
> Hi Everyone, I have a php-cli script that does snmp queries and writes

> to a file. The script runs fine when I run it from the command line, 
> but there is a problem when I give the job over to cron. I have tried 
> playing around the the file permission and ever set it to 777, but
still no luck.
>
> The error: Warning: fopen(../n_tunnel_UpDownStates.dat): failed to 
> open
> stream: Permission denied in /var/www/mrtg/runfive/hawk.php on line 89
>
>
> Any ideas????
>
> To read FirstRand Bank's Disclaimer for this email click on the 
> following address or copy into your Internet browser:
> https://www.fnb.co.za/disclaimer.html
>
> If you are unable to access the Disclaimer, send a blank e-mail to 
> firstrandbankdisclaimer at fnb.co.za and we will send you a copy of the 
> Disclaimer.
>
> --
> ubuntu-za mailing list
> ubuntu-za at lists.ubuntu.com
> https://lists.ubuntu.com/mailman/listinfo/ubuntu-za
>
>

--
ubuntu-za mailing list
ubuntu-za at lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-za
To read FirstRand Bank's Disclaimer for this email click on the following address or copy into your Internet browser: 
https://www.fnb.co.za/disclaimer.html 

If you are unable to access the Disclaimer, send a blank e-mail to
firstrandbankdisclaimer at fnb.co.za and we will send you a copy of the Disclaimer.



More information about the ubuntu-za mailing list