Support

Akeeba Backup for Joomla!

#13831 Front-end Backup with off-site storage (Amazon S3) - PHP Warning

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 nicholas on Sunday, 14 October 2012 09:19 CDT

SmossErKen
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?)? Yes
Joomla! version: 2.5.7
PHP version: See attached logfile
MySQL version: See attached logfile
Host: (optional, but it helps us help you)
Akeeba Backup version: 3.6.7

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:
Hi Nicholas,

I'm testing out the different 'post-handling' options. When using Amazon S3, the backup is executed correctly and the transfer of the file to Amazon S3 works fine. But when I check the logfile I noticed a PHP warning :

[121014 01:55:55] PHP WARNING on line 898 in file /administrator/components/com_akeeba/akeeba/plugins/utils/amazons3.php:
[121014 01:55:55] curl_setopt() [function.curl-setopt]: CURLOPT_FOLLOWLOCATION cannot be activated when safe_mode is enabled or an open_basedir is set

In the configuration manager I tried out different settings for the jpa-file :
-> No Archive Split
-> Archive Split 20MB
-> Archive Split 10MB

These settings all give the same error(s), but the backup is transfered correctly.

Best regards
Kind regards,
Chris K.
Redpider Webdesign

nicholas
Akeeba Staff
Manager
This is not an error, it is a warning. Long story cut short, you can ignore it. If you had to know why you should ignore it you would be a developer or a host and already know why you should ignore it, so I will spare you the technical details which are of no interest to you.

If you really want to do something about it (even though you absolutely don't have to and it's an overkill if you do) you have to disable PHP's Safe Mode and remove any open_basedir restrictions from php.ini. However, this means that you have to use a dedicated server. On a shared host the open_basedir restrictions are used for security reasons.

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!

SmossErKen
Hi Nicholas,

Thx for your reply. I know it is not an error but a warning (as I wrote in my request). I'm also familiar with PHP, Javascript, ... and consider myself a developper. Just not that familiar with Joomla! that I started using about 6 months ago (don't waste time on reinventing good stuff).
I also dind't have any intention to disable PHP's Safe Mode and/or remove open_basedir restrictions as they would compromise the security of the website on a shared hosting. Just wanted to inform you about it.

Anyway, after wondering around in the JED for 6 months and looking at lots of extensions (in all domains) Akeeba Backup Pro & Admin Tools Pro come out as the best there is to find in their categorie (backup & security). Both great extensions and the support is exeptionally good !

Best regards,
Chris
Kind regards,
Chris K.
Redpider Webdesign

nicholas
Akeeba Staff
Manager
OK, Chris, maybe it's time for me to give you the gory details after all :)

In order to connect to Amazon S3 we use PHP's cURL extension to talk to Amazon AWS Web API. One of the standard cURL flags we try to set is the CURLOPT_FOLLOWLOCATION which tells cURL to follow redirections. This is required in the rare case where you put an extra slash at the end of the S3 directory and Amazon issues a 303 HTTP redirect. In order to prevent an error from being sent to the browser we use that at-sign ("mute") operator in front of curl_setopt(). However, in the interest of debugging Akeeba Backup and making bug reports by our users much easier, we also install an error handler. This handler will write all warnings and notices to the backup log file. In this case I already know that if Safe Mode or open_basedir restrictions are in effect that line will throw a warning. That's why I suppress it and when I see it in the log I am not worried - unless I see that this is what caused a backup failure.

I hope that helps you understand the inner workings of the code and shed light to the reason of this warning being logged.

Thank you very much for your kind words!

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!

SmossErKen
Hi Nicholas,

Thx for making the effort to give this extra information. As I said before : exeptional good support :) !

Best regards,
Chris
Kind regards,
Chris K.
Redpider Webdesign

nicholas
Akeeba Staff
Manager
Thank you, Chris!

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!

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!