RE: [PHP] question about a cron job

From: Date: Mon, 17 Jan 2005 15:04:28 +0000
Subject: RE: [PHP] question about a cron job
References: 1  Groups: php.general 
Request: Send a blank email to php-general+get-206545@lists.php.net to get a copy of this message
>> #this is only for testing a new cronjob, every minute >> * * * * * /usr/local/bin/php > /www/r/rester/htdocs/phpList_cronjob/process_cronjob.php >>> /www/r/rester/htdocs/phpList_cronjob/cron.log 2>>&1 >> > > The new one doesn't seem to want to run until after 3:01 or 3:02. > Shouldn't the > sever just run it every minute? Yes, it should. Cron normally emails any output (including messages to stderr) to the owner of the cron job. In this case you have "2>>&1" at the end of your command which should be "2>&1". On my machine executing a command with "2>>&1" results in: -bash: syntax error near unexpected token `&' which might explain why your job isn't running. If I setup a test job that looks similar to yours, the above error output is emailed to me. Jay Blanchard wrote: > You have to specify each minute... "* * * * *" is sufficient for that. I've got a couple of jobs on a box here that run every minute and that's the way they are entered in my crontab... HTH

« previous php.general (#206545) next »