Backups not complete and I can't see anything in Amazon S3 without log
-
Previous posting just comes up blank when I click on it so re-writing.
I’m trying UpdraftPlus for the first time on a fairly large site. I would so love this to work easily as we are having a lot of trouble backing up this site and I’ve lost count of the number of ways I’ve tried.
I’ve got the connection to Amazon S3 working and the plugin created its own new bucket.
Even after 8 partial backups the bucket remains empty when I look at it with Cyberduck or with Amazon’s own web front end.
The plugin reports:
Web-server disk space in use by UpdraftPlus: 7173.5 GbI’m trying to include a log but perhaps it is too long for this forum? How do I send you a log?
-
Hi Brian,
The log shows that your web server only allows PHP 15 to 20 seconds to run at a time, and your backup is a few hundred megabytes. This means that the resources available to run the backup in are rather low.
However, having said that, UpdraftPlus is designed to cope with that. In this case it looks like it is failing to detect that progress is still being made, and giving up prematurely.
Please try this version (i.e. de-install, then re-install this one):
https://downloads.www.ads-software.com/plugin/updraftplus.1.5.6.zip
(You may need to wait a few moments before that link works – www.ads-software.com hasn’t yet created it, though I’ve sent through the necessaries for it).Then send me a log file again (you’ll need to start a backup and then leave it running for a couple of hours for us to be able to see if it’s doing any better).
David
I can’t download from that link (1 hour or so later).
If you can send by some other method (dropbox etc) let me know and I will test it ASAP.
I am also having a problem using Google Drive with symptoms that may be similar. Here is a debug log file snippet…
0000.160 (2) Googledrive chunked upload: 0 % uploaded (URL: https://docs.google.com/feeds/upload/create-session/default/private/full/folder%3A0B2JwZUCzCNIEZWhLbl83dGlSX2c/contents?convert=false&upload_id=AEnB2UrBvyi7S6jM0WHwgeybX76erWupxMVJu5yv1YyTcOmwh81h59SGO5q1IIQi_tl_ZGC55adlXws8Px1BvfjD_U_N5XTJVA)
0002.492 (2) Googledrive chunked upload: 10 % uploaded
0004.805 (2) Googledrive chunked upload: 11 % uploaded
0007.327 (2) Googledrive chunked upload: 11 % uploaded
0009.673 (2) Googledrive chunked upload: 11 % uploaded
0025.009 (2) An error occurred during GoogleDrive upload (2)
0025.009 (2) An error condition has occurred for the first time on this run
0025.010 (2) Operation timed out after 15 seconds with 0 bytes received
0025.011 (2) ERROR: backup_2013-04-08-1404_Rightdrive_19c4ce68b6fe-uploads.zip: Failed to upload to Google Drive
0025.012 (2) backup_2013-04-08-1404_Rightdrive_19c4ce68b6fe-db.gz: Attempting to upload to Google Drive
0025.013 (2) /home/linweb13/g/gocarfinance.co.uk/user/htdocs/wp-content/updraft/backup_2013-04-08-1404_Rightdrive_19c4ce68b6fe-db.gz: Attempting to upload file to Google Drive.
0025.992 (2) Uploading file with title backup_2013-04-08-1404_Rightdrive_19c4ce68b6fe-db.gz
0025.993 (2) Googledrive chunked upload: 0 % uploaded (URL: https://docs.google.com/feeds/upload/create-session/default/private/full/folder%3A0B2JwZUCzCNIEZWhLbl83dGlSX2c/contents?convert=false&upload_id=AEnB2Uoops-V_eUW6hco80mh6xPvPbPSHRdVsdsuNO9yQO5G57pnjmEY3WspoKEoVfC9DNLOmpfwSmmcN-wKjtcptS0uKua_1Q)
0028.960 (2) The file was successfully uploaded to Google Drive in 2.968 seconds at an upload speed of 77 kB/s.I think I was too hasty, backup now completed ok after retries.
Many thanksChrisjn52: Yes, you should wait until it’s finished – your report comes only after 10 minutes; you should wait until the log finishes with a message saying that backup has failed and won’t be attempted again before concluding that it finally failed.
brianoflondon: I’ve emailed the WordPress plugins team to find out why those zips are still delivering up 404 messages. This is the free support forum, so we try to get everything fixed properly rather than quicker work arounds… commercial support is available in the shop at updraftplus.com if that’s needed.
David
OK. I’ll keep checking to see if that download becomes available.
Still getting file not found on that link. Keen to see if I can get this plugin working. I’m kinda reluctant to spring for the $55 before I know it works but I’m fairly certain if it does work I will contribute financially as it will be a very important part of our site and I’ve been having a devil of a time backing it up.
Hi Brian,
When I said we should wait for them to fix the link, I was thinking we’d be waiting about an hour. They must be having a busy day.
Anyway, here you go – here’s another link for it:
https://updraftplus.com/wp-content/updraftplus-1.5.6.zip
David
Hi Brian,
We’ve been communicating by email, but I’ll put the results in here so that it’s searchable by others who may have the same problem.
This answer is definitive – I spent a looong time getting to the bottom of this, and eventually did…
Your web hosting company is using LiteSpeed as a web server. Not wrong in itself. But LiteSpeed has an issue with killing off PHP processes when the other end (usually the browser – but in the case of WordPress’s scheduling engine, it is WordPress itself doing a “loop back”) closes the connection. This is leading to the backup jobs being killed prematurely – after a maximum of 15 seconds on your setup.
Googling shows that this, as expected, affects all backup plugins – because all backup plugins run via the scheduler and get killed by LiteSpeed.
We have a workaround here, which worked for someone else as recently as yesterday:
Sadly the first work-around didn’t work in your case. I’m not expert enough in LiteSpeed configuration (and don’t have access to your LiteSpeed configuration anyway) to know why not. But if you can communicate with your web hosting company, they may know.
The second work-around is the “WordPress alternative cron (scheduler)” system, mentioned in the same article. This got some extra time, but only up to 30 seconds maximum. This 30 seconds cut-off is coming from your use of CloudFlare as a reverse proxy, which cuts the connection after a maximum of 30 seconds, and apparently usually less – and then LiteSpeed, seeing the connection cut, kills the process.
The third factor is that your site is enormous. The fourth is that your web hosting server is underpowered – by our tests, it’s only giving about 40% of the performance that we typically see. (This is talking about CPU power, not memory usage or maximum run-time which your hosting company mentioned).
Putting those factors all together you get a toxic combination. When UpdraftPlus wakes up to resume the backup job, which it has to do many times given the short run times + low resources it gets, eventually it gets to a state where it requires 15 seconds to scan the existing half-a-gigabyte zip file to see how far it got, finding 8,000 files inside it. Then in the few seconds remaining, it finds some new files to put inside to continue the backup. Then it issues the command to add them to the zip file; but time runs out before this can occur. This “deadlock” is being reached inevitably because the time taken to scan the existing zip file takes up an increasing amount of the few seconds available until it is taking so much time that nothing else can be achieved.
Technically there are only 3 ways to resolve this:
1) Re-configure LiteSpeed to not kill connections when the other end goes away. Only your web hosting company has control over this. If you do this, then remote the ALTERNATE_CRON line from your wp-config.php
or:
2) Re-configure CloudFlare to keep the connection open for more than 30 seconds when they fetch a resource. I don’t know if they even have a setting for this.
or:
3) Move to a web hosting company that either doesn’t use LiteSpeed (which is about 99.9% of them, not that that’s because of the technical merits – it’s just the market share for historical reasons), or if it does, has more powerful CPUs. If you email me I can make a recommendation.
If you’re totally loathe to move your hosting and if they can’t fix it, then you could fund some changes to UpdraftPlus to more aggressively cache some things that would allow us to get more out of the 15 seconds… but we’re not likely to get around to that by ourselves any time soon because large site/underpowered server/web server that kills connections prematurely is a toxic combination and the problem really needs addressing there if it can be.
David
Thanks David for all your work. I’ve been busy with various other things for a few days but I will now go back to work on this and see what I can do.
Hi Brian,
I thought of a way this could be fixed without your needing to move hosting. The problem is that Litespeed terminates connections when the connecting end goes away. (AFAIK no other webserver does this). This problem then becomes toxic because Cloudflare always terminates the connection after 30 secnods.
The solution would be to produce a new WordPress plugin which over-rides the callback method used in WordPress’s scheduler system, to not go via Cloudflare. This would have no impact on site performance, because the scheduler only runs a tiny number of times a day, and does so in in the background (users don’t see the results – it’s not part of normal page loading).
Since this issue only affects people combining LiteSpeed (market share immeasurably small – https://news.netcraft.com/archives/2013/03/01/march-2013-web-server-survey.html) and Cloudflare, it would be a poor use of time for me to put this feature into UpdraftPlus. But if you’re willing to fund it – say, $65 – then I would release the plugin into the WordPress plugins directory. It could have other uses.
If you want to take that up then contact me via email – the www.ads-software.com people don’t like commercial discussions in their forums.
David
- The topic ‘Backups not complete and I can't see anything in Amazon S3 without log’ is closed to new replies.