The free forums are no longer in use. It remains available as read-only archive.
11:28 am
September 22, 2014
Hi everyone!
I'm having problems using the XCloner auto backup via cron feature, when using XCloner 3.5.1 with joomla 3.x. I hope someone can help me…
Here is the situation so far:
My current webhost provides a task scheduling funcion and I have configured the cronjob there. This is all configured by means of form filling, but in the end the command being executed is has follows: /usr/local/bin/php.ORIG.5_4 -c /usr/local/lib/php.ini-2 /homez.401/sysreseajm/www/xxxx/administrator/components/com_xcloner-backupandrestore/cloner.cron.php
At first, running this script was giving me the "To run this script you need to create a custom config file inside XCloner config (…)" error, but I've read somewhere in the forums that this could be solved by deleting the following lines from the cloner.cron.php:
if(!isset($argv[1]) ) {
echo "<h2>".$topErrorLine1."</h2>n";
echo "<strong>".$topErrorLine2."</strong>n";
exit;
}
Now here comes the weird part. By doing this i can get the cron to run IF I call it from the browser (using the cloner.cron.php address, ouch security :S), but it creates numerous backups instead of only one. But the worst is that, when called from my host's task scheduler, I now get another error, which I have no clue how to solve:
Your backup directory /home/sysreseajm/www/xxxx/administrator/backups is not writeable or does not exists!
Which is weird because I know from running in the browser, that the folder is indeed writable :S
Can someone help me with this? I'll gladly provide more details if necessary…
12:35 pm
September 26, 2010
To properly run the cronjob you need to save a custom cron config, check the XCloner Config->Cron tab, then use that name within your cron command as
/usr/local/bin/php.ORIG.5_4 -c /usr/local/lib/php.ini-2 /homez.401/sysreseajm/www/xxxx/administrator/components/com_xcloner-backupandrestore/cloner.cron.php my_custom_name.php
Once that is done, make sure the /home/sysreseajm/www/xxxx/administrator/backups folder has 777 permissions.
Hope it helps.
1:08 pm
September 22, 2014
7:44 am
September 26, 2010
4:01 pm
September 22, 2014
OK, I've hardcoded the config name in the script and can now run it. I'm back to square one with the error:
Your backup directory /home/sysreseajm/www/xxxx/administrator/backups is not writeable or does not exists!
I've chmod'ed the folder to 777 and double checked the premissions, but to no avail!
Also I noticed the script also sends a PHP warning:
PHP Warning: filesize(): stat failed for /home/sysreseajm/www/xxxx/administrator/backups/ in /homez.401/sysreseajm/www/home/administrator/components/com_xcloner-backupandrestore/cloner.cron.php on line 186
Do you have any ideia how to solve this?
EDIT: Fyi in my modified script, line 186 is "$bsize = getFileSizeText(filesize($source_file));"
6:13 am
September 26, 2010
6:50 pm
September 22, 2014
5:02 pm
September 22, 2014
I finally figured it out!
Thank you for your answers Ovidiu, the problem was really on the side of my host. And well… was kinda dumb
So I'll leave here the solution in case anyone else is using OVH as a provider and has the same problem.
As I said the path,
/home/sysreseajm/www/xxxx/administrator/backups
is said to be OK in the XCloner Manager, but when the cron job executes from the OVH task manager, they execute it from the starting folder "homez.401" (like you can see in my first post).
So I wondered and changed the folder in the XCloner manager, and voilá, the path
/homez.401/sysreseajm/www/xxxx/administrator/backups
is not only ALSO OK to the XCloner manager, but now everything goes fine when the cron job execute from the OVH task manager! Hurray!
Thanks again for the support Ovidiu, and thanks even more for making such an awesome plugin!
12:32 pm
April 19, 2015
Hi cr0xfyre,
how you hardcoded the config name in the script?
I've been dealing with the same problem since 2 days now...
I also changed the backup location adding OVH's naming...
Thanks for sharing the solution!!! 🙂
I just don't know how to hardcode the config name in the .php to call my custom cron...
Thanks!
2:39 pm
September 22, 2014
Hi Pablo,
I believe I ended up using the main config instead of a custom one. For that I only had to comment the following lines in the cloner.cron.php (they're right at the beginning):
1 Guest(s)