Softaculous


Topic : Cron Job Blues


Posted By: jficklin on November 25, 2015, 12:02 am
So, I've written a php script to delete files inside of a folder that I want to run as a cron job. When I run the script over SSH, it works great. As soon as I add it as a cron job on Webuzo, nothing happens. I'm wondering if this is some sort of a permissions thing or maybe just something I'm overlooking.

The cron job command is:

/usr/bin/php -q -d safe_mode=Off
/home/myusername/CronTest


This is the script I grabbed and customized from stackoverflow:

$files = glob('path/to/temp/*'); // get all file names
foreach($files as $file){ // iterate files
  if(is_file($file))
    unlink($file); // delete file
}

Posted By: peopleinside on November 27, 2015, 10:16 am | Post: 1
Hi,
please look here:
http://www.webuzo.com/wiki/Add_Cron_Job

In the screen are showed Cron are compiled with all *
Do you set a day and time for the cron job? Like every 5 minutes?

Can you post here a screen of your Cron Job page?
Maybe this can help better to understand what can be the problem.

If this not solve the issue maybe Webuzo Team can ask more information.
Thank you!
Have a great day!


-----------------------
PeopleInside  :angel:

Web, security, open source passionate.

Posted By: peopleinside on November 27, 2015, 10:18 am | Post: 2
Maybe also that can be useful
http://www.webuzo.com/blog/how-to/manage-cron-jobs-in-webuzo-1633.html


-----------------------
PeopleInside  :angel:

Web, security, open source passionate.

Posted By: nikhil89 on November 27, 2015, 1:49 pm | Post: 3
Hi Justin,

We have replied to your ticket #497896. Please check the same and revert back to us, if you need any further information.

Posted By: jficklin on November 27, 2015, 4:02 pm | Post: 4
Thanks guys.  Looks like I may have just had the timing set wrong so I wasn't seeing it update.  Will verify that shortly.

Posted By: nikhil89 on November 28, 2015, 2:15 pm | Post: 5
Hi Justin,

No issues. Please let us know if you still face the issue. We will be happy to help you.

Posted By: jficklin on November 28, 2015, 4:28 pm | Post: 6
Everything working.  Thanks for the help!

Powered By AEF 1.0.8 © 2007-2008 Electron Inc.