Support

Akeeba Backup for Joomla!

#8733 Strange Dropbox behavior

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, 12 December 2010 16:59 CST

user13366
I have three sites on a VPS for which I run daily backups as cron jobs, and upload the files to Dropbox. All three create relatively small files, less than 12MB, and run quickly, so I run them at 10 minutes interval. The first one that runs keeps getting the SSL error on post-processing (Unknown SSL protocol error in connection to www.dropbox.com:443), the other two complete and upload the files without problem.
The configurations of the three sites are identical, so I assumed it was a permission problem. I tried to run the backup from the command line while logged in as root, or nobody, or a regular user, and I had inconsistent results. Sometimes it ran, sometimes not, and I could not see a pattern.
Finally, I changed the order in which the backups are performed, and I found that the one that runs first consistently fails, no matter which site it is, then the other two run fine. I was able to reproduce that from the CLI: the first try will fail; the next ones within a reasonable time (less than an hour, apparently) will run fine, even if it is the exact command, or are run as a different user or on a different site. I am not able to pinpoint the time interval after which it resets itself, or correlate it to time outs or cache retention values, so I do not know where to look next.
Perhaps this can help find a problem in the Dropbox interface or in Joomla! itself, perhaps it is still a problem with my server. Any suggestions would be appreciated.
I am running Akeeba 3.1.5 and Joomla! 1.5.22 on a CentOS VPS, with Apache 2.2, and PHP5.
Jacques

steph.s
Apparently, DropBox experiences periodic short outages in its web interface (which is used by Akeeba Backup). If you try to backup during that time, you get those errors. That is why it works sometimes and doesn't work sometimes, not sure why the first would always fail, thank you for the information I will pass it on to Nicholas.

nicholas
Akeeba Staff
Manager
Had you logged in to the DropBox web interface prior to running any of the backups? If you did, did you try logging out of it before running the backups? If you are still logged in the DropBox web interface when a backup runs, it won't be able to send the files to DropBox.

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!

user13366
Hello, and thank you for the response.
I was not logged in to Dropbox in any of the cases I described. The problem occurs regularly at night and I know none of my computers is logged in. Besides, that would not explain why the first attempt fails and the following ones don't.
I have now found a work-around that seems to work: I have created a profile that excludes the whole site except for one small file. I run the backup with that profile 5 minutes before running the regular backups. The first one fails, then the real ones work fine and transmit the files to Dropbox as expected.
One possibility is that the Dropbox server is too slow responding to the first request, but much faster on subsequent ones when the account info is in cache. That could be sufficient to exceed some time-out value in the protocol, and return an error when the program tries to establish the connection to the Dropbox server. I could be worth trying to put a retry loop around the code that establishes the connection to see if it makes a difference. I can reproduce the failure very regularly, and I would be happy to run tests for you if it can help.
Thank you,
Jacques

nicholas
Akeeba Staff
Manager
I am tempted to say that the server is somehow caching DNS queries and they are stale by the time of the first backup. As you suggested, I will add a retry loop in the DropBox engine so that the upload is being tried twice before it is deemed as failed.

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!

user13366
Hello Nicholas,
Let me know if you want me to run some tests or run a modified version to measure timings, or anything else I can check.
Thank you,
Jacques

nicholas
Akeeba Staff
Manager
Hello Jacques,

I had some time today to attack this issue. I have uploaded pa developer's release which addresses this issue by retrying up to two times after the first upload failure. Please check it out and tell me if it works fine for you. Thank you!

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!

user13366
Hello Nicholas,
I just installed the developer version SVN 3.2.2 and ran a test from the command line with my dummy profile. It ran well and copied the file to Dropbox, on the first try. It is a bit early to be definitive, but the changes appear to have made a difference. There is no point to run another test right away because it used to run that way, but I will let it run at night and report after a few days.
I attach a debug level log file, if it is of interest to you.
Thank you,
Jacques

nicholas
Akeeba Staff
Manager
This is a positive result. Please let me know if the CRON job also worked. Thank you for your feedback!

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!

user13366
Hello Nicholas,
The cron job has been fine for two days in a row, it seems the fix is working.
I am not using all the features, obviously, but I have not seen any other area of concern with 3.2.2 either.
Thank you,
Jacques

nicholas
Akeeba Staff
Manager
That's very good news! I am now considering this patch as finalized and will include it in the next Akeeba Backup release.

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!

user13366
Hello Nicholas,
Thank you for the excellent support and the quick turnaround.
I don't expect to need it, but I just subscribed to your AkeebaDeluxe level support because I feel that it is fair for the level of service that I received.
Cheers,
Jacques

nicholas
Akeeba Staff
Manager
You're welcome! It's a pleasure being able to help. Thank you for your subscription!

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!