XFileSharing Pro - How to test wheather cron.pl

Message
Author
ihavenoidea
Posts: 19
Joined: Oct 14, 2009 11:21 pm

How to test wheather cron.pl

#1 Postby ihavenoidea » Oct 15, 2009 6:51 pm

I've put cron.pl in the cron job list but im wary whether its running every hour or not. Is there a way I can check?
I would have just checked if theres any files over 30 days with 0 downlods but I havent launched my site yet so theres no files lol

admin
Site Admin
Posts: 1839
Joined: Mar 22, 2006 12:32 pm

#2 Postby admin » Oct 16, 2009 4:29 am

You can add logging for your cron job.


So, cron line will looks like:

Code: Select all

cd /var/www/cgi-bin;./cron.pl >/var/www/cgi-bin/cron.log 2>&1
But make sure that /var/www/cgi-bin/cron.log exists and writeable.

geekev69
Posts: 45
Joined: Dec 05, 2009 6:12 am

cron

#3 Postby geekev69 » Jan 18, 2010 5:32 am

I just found cron command from installation guide like this.

cd /var/www/cgi-bin;./cron.pl >/dev/null 2>&1

is it okay? there is no cron.log mention

PowerChaos
Posts: 521
Joined: Dec 19, 2009 5:12 pm

#4 Postby PowerChaos » Jan 18, 2010 5:13 pm

i tryed out the cronlog with cpanel

it got a option to send cronlogs to your email on succesfull and failt cronjobs

for the rest , i think both will works

i think that the /dev/null sends a email then (not sure)

the other way to check if cronjob works is by making a small test file and wait 1 day , or just remove a file from the database and see if it is updated after 1 hour

Greets From The Crasher