Using Perl to run cron

Last modified: November 30, 2008 - 13:10

If you're having problems with cron using curl and wget is not allowed on your server try out the curl call from the shell on another box - you may find you get HTML delivered saying "page not found."

If this is the case you can also use Perl to perform the call to the cron script.

You need command line access to Perl and the LWP::Simple module installed. Your crontab entry then becomes:

45 * * * * perl -MLWP::Simple -e "getprint 'http://yourdomainhere/cron.php'"

 
 

Drupal is a registered trademark of Dries Buytaert.