[PHP] cron job for php not working

2004-05-20 Thread Merlin
Hi there,
I am trying to install following cron job:
0 6 * * * php /home/www/project/app_cron/follow_up_new_members.php
The script works, if I run this php /home... line manually it works out, but 
it does not automaticaly at 6 am as supposed.

I do also see in /var/log/messages that the cron job has happened at that time, 
but the file did not generate the emails like it supposed to.

I am running the crontab as webserver user.
Thanx for any helpful ideas on that,
Merlin
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


RE: [PHP] cron job for php not working

2004-05-20 Thread Jay Blanchard
[snip]
I am trying to install following cron job:
0 6 * * * php /home/www/project/app_cron/follow_up_new_members.php

The script works, if I run this php /home... line manually it works
out, but 
it does not automaticaly at 6 am as supposed.

I do also see in /var/log/messages that the cron job has happened at
that time, 
but the file did not generate the emails like it supposed to.
[/snip]

At the command line type which php and it will return the full path to
php. Modify your line in the crontab with the full path...

0 6 * * * /usr/local/bin/php
/home/www/project/app_cron/follow_up_new_members.php

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] cron job for php not working

2004-05-20 Thread James E Hicks III
On Thursday 20 May 2004 11:35 am, Jay Blanchard wrote:
 At the command line type which php and it will return the full path to
 php. Modify your line in the crontab with the full path...

 0 6 * * * /usr/local/bin/php
 /home/www/project/app_cron/follow_up_new_members.php

I always put the #!/usr/local/bin/php at the top of all my command line php 
scripts. Mine is actually #!/usr/bin/php. Then chmod 755 the file so that it 
can execute.

James Hicks

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] cron job for php not working

2004-05-20 Thread Tim Traver
It looks like that cron line is making it so that the command runs as the 
user php...

so, you should check if that user has permission to run the script.
Tim.
At 08:33 AM 5/20/2004, Merlin wrote:
Hi there,
I am trying to install following cron job:
0 6 * * * php /home/www/project/app_cron/follow_up_new_members.php
The script works, if I run this php /home... line manually it works out, 
but it does not automaticaly at 6 am as supposed.

I do also see in /var/log/messages that the cron job has happened at that 
time, but the file did not generate the emails like it supposed to.

I am running the crontab as webserver user.
Thanx for any helpful ideas on that,
Merlin
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php