Support

Akeeba Backup for Joomla!

#16635 cron override

Posted in ‘Akeeba Backup for Joomla! 4 & 5’
This is a public ticket

Everybody will be able to see its contents. Do not include usernames, passwords or any other sensitive information.

Environment Information

Joomla! version
n/a
PHP version
n/a
Akeeba Backup version
n/a

Latest post by on Wednesday, 07 August 2013 18:00 CDT

allright
Mandatory information about my setup:

Have I read the related troubleshooter articles above before posting (which pages?)? yes
Have I searched the tickets before posting? yes
Have I read the documentation before posting (which pages?)? 88-9
Joomla! version: 2.5.11
PHP version: 5.3
MySQL version: (unknown)
Host: (optional, but it helps us help you) siteground
Akeeba Backup version: 3.7.10

EXTREMELY IMPORTANT: Please attach a ZIP file containing your Akeeba Backup log file in order for us to help you with any backup or restoration issue. If the file is over 2Mb, please upload it on your server and post a link to it.

Description of my issue:
I am trying to have a cron job override the amazon key and secret key with the cron job:
/usr/bin/php -q /home/allrigh1/public_html/cli/akeeba-backup.php --profile=1 --override='engine.postproc.s3.accesskey=my access key' --override='engine.postproc.s3.secretkey=my secret key' (no line breaks)

The log file shows an error, so maybe that is it. If the cron does not override the configuration, it works as expected.

thanks
Neil

nicholas
Akeeba Staff
Manager
In the output of the CRON script you should see a line reading:
Configuration variables overriden in the command line:

followed by all of the overrides that are present in the command line. You should see the two overrides you have defined and they should be taken into account.

That said, I have no idea what the -q option is supposed to do in the command line and I wouldn't put it there.

Nicholas K. Dionysopoulos

Lead Developer and Director

πŸ‡¬πŸ‡·Greek: native πŸ‡¬πŸ‡§English: excellent πŸ‡«πŸ‡·French: basic β€’ πŸ• My time zone is Europe / Athens
Please keep in mind my timezone and cultural differences when reading my replies. Thank you!

allright
Thanks Nicholas,

The -q is quite mode. I removed it and got some interesting messages:

Configuration variables overriden in the command line:
engine.postproc.s3.secretkey, 0

"Configuration variables overriden in the command line:
engine.postproc.s3.secretkey, 0"

does this mean the secretkey is 0? If so, something is not getting passed along.

additionally, at the end of the log it said that the accesskey was missing, even though I entered it in the cron string. Both the access and secret keys are in single quotes if that matters.

nicholas
Akeeba Staff
Manager
Ah, nice catch! They should be in double (not single) quotes. Double quotes instruct the shell to pass its contents verbatim to the programme being called, which is a requirement for the equals operator to work. If you don't use doubles quotes the second equals operator and anything to its right is ignored, hence the zero value.

Nicholas K. Dionysopoulos

Lead Developer and Director

πŸ‡¬πŸ‡·Greek: native πŸ‡¬πŸ‡§English: excellent πŸ‡«πŸ‡·French: basic β€’ πŸ• My time zone is Europe / Athens
Please keep in mind my timezone and cultural differences when reading my replies. Thank you!

allright
same problem with double quotes

nicholas
Akeeba Staff
Manager
You are doing something wrong. Most likely you missed a double quote or two. This is the command line you have to use. Copy & paste it, changing the access and secret keys, making sure that you do not remove the double quotes after them.

/usr/bin/php /home/allrigh1/public_html/cli/akeeba-backup.php --profile=1 --override="engine.postproc.s3.accesskey=ACCESSKEY" --override="engine.postproc.s3.secretkey=SECRETKEY"

Nicholas K. Dionysopoulos

Lead Developer and Director

πŸ‡¬πŸ‡·Greek: native πŸ‡¬πŸ‡§English: excellent πŸ‡«πŸ‡·French: basic β€’ πŸ• My time zone is Europe / Athens
Please keep in mind my timezone and cultural differences when reading my replies. Thank you!

allright
I copied your script and put the accesskey and secretkey in, and got the same result, nothing sent to amazon.

The attached is the email I received showing what happened. The subject line is the cron job line with the amazon security keys (I have changed them).

I will ask on siteground as well, but do you have any ideas as to what is happening?

nicholas
Akeeba Staff
Manager
I have checked again and again; the overrides are really taken into account. First try removing the akeeba-backup.php file from the cli directory and install Akeeba Backup Professional twice, without uninstalling it.

If that doesn't help, try entering your S3 credentials in Akeeba Backup's configuration page and take a backup from the back-end. If that works and the transfer does start (even if it times out and the backup process halts with an error) try running the backup from the CRON job, without removing the S3 credentials. If that works, too, I am left with no explanation as to what is happening.

Nicholas K. Dionysopoulos

Lead Developer and Director

πŸ‡¬πŸ‡·Greek: native πŸ‡¬πŸ‡§English: excellent πŸ‡«πŸ‡·French: basic β€’ πŸ• My time zone is Europe / Athens
Please keep in mind my timezone and cultural differences when reading my replies. Thank you!

allright
It seems to be working now after reinstalling.

Interestingly, the profile id recorded in the cron job summary is not the one that ran.

thanks

nicholas
Akeeba Staff
Manager
I am pretty sure it runs the profile ID it reports.

Nicholas K. Dionysopoulos

Lead Developer and Director

πŸ‡¬πŸ‡·Greek: native πŸ‡¬πŸ‡§English: excellent πŸ‡«πŸ‡·French: basic β€’ πŸ• My time zone is Europe / Athens
Please keep in mind my timezone and cultural differences when reading my replies. Thank you!

System Task
system
This ticket has been automatically closed. All tickets which have been inactive for a long time are automatically closed. If you believe that this ticket was closed in error, please contact us.

Support Information

Working hours: We are open Monday to Friday, 9am to 7pm Cyprus timezone (EET / EEST). Support is provided by the same developers writing the software, all of which live in Europe. You can still file tickets outside of our working hours, but we cannot respond to them until we're back at the office.

Support policy: We would like to kindly inform you that when using our support you have already agreed to the Support Policy which is part of our Terms of Service. Thank you for your understanding and for helping us help you!