Sentora Support Forums

Full Version: Cron Jobs not executing
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Hi,

i've created a simple test.php in my domain root directory. This file just appends a string in a .txt file. Easy. Of course i tested it and it works.
The problem is...the cron job never executes. 

Script: mydomain.tk/test.php
Run every 1 minute.

It's added normally, but it's not really executed. Am I missing something?
(01-26-2017, 01:08 AM)Saveriott12 Wrote: [ -> ]Hi,

i've created a simple test.php in my domain root directory. This file just appends a string in a .txt file. Easy. Of course i tested it and it works.
The problem is...the cron job never executes. 

Script: mydomain.tk/test.php
Run every 1 minute.

It's added normally, but it's not really executed. Am I missing something?

This may help: http://forums.sentora.org/showthread.php?tid=491
I've added the following cron script:

mydomain.tk/new_curl.php

new_curl.php:


PHP Code:
<?php
include('curl.php');
?>


curl.php:


PHP Code:
<?php
$file 
'people.txt';
$person "John Smith\n";
file_put_contents($file$personFILE_APPEND LOCK_EX);
?>


not executing..
(01-26-2017, 09:41 AM)Saveriott12 Wrote: [ -> ]I've added the following cron script:

mydomain.tk/new_curl.php

new_curl.php:


PHP Code:
<?php
include('curl.php');
?>


curl.php:


PHP Code:
<?php
$file 
'people.txt';
$person "John Smith\n";
file_put_contents($file$personFILE_APPEND LOCK_EX);
?>


not executing..

Huh
Did you read that other post? The above means nothing if you did not read that post and make the proper changes if needed. Is your cron service even running?
"make sure /var/spool/cron owned by apache:apache and permissions 770" - Done.
"make sure /var/spool/cron/apache owned by apache:apache and permissions 660" - i get "no such file or directory".
This is what i have in /var/spool/cron/:
atjobs, atspool, crontabs .

And "cron" folder is owned by "root" , not apache:apache.