Snapshot backups stall

Still cannot complete a snapshot or backup. Patrick and Nahid worked with me and we eliminated several possible issues. We could make a snapshot of Plugins alone, but could not complete a snapshot with even a basic theme (TwentyNineteen) and only WPMU DEV and Snapshot Pro activated. Dreamhost tech suggested we run PHP 7.2 rather than 7.0, and we agreed. Dreamhost also said there were no errors at their end, and the max_execution was 1500, but it looked like it was still at 500. Still, no one could determine why Snapshot and managed Backups will not work.

  • Nithin
    • Support Wizard

    Hi Jason,

    Seems like the issue is more specific with Snapshots created to your local server. I checked your system and could notice the issue.

    I could notice there was a line in wp-config.php which was limiting the max_execution_time from 1500 to 500:

    @ini_set( 'max_execution_time', 500 );

    I have commented out that line so that 1500 value would get used. Once done, I have excluded more big files in your system, which you can see listed under Snapshot > Settings page.

    And disabled the Updraft plugin temporarily, and ran a new Snapshot, but this time the snapshot stopped when it reached media/2018/11/ folder.

    Could notice the snapshot works fine when it’s taken in parts. I’m afraid, this needs further troubleshoot. I’m bringing this into our Second Level Support(SLS) teams attention, to see whether there is any fix to help get snapshot work smoothly.

    I have enabled the Updraft plugin back. Will keep you posted once we get further feedback from the SLS team asap. Have a nice day ahead. :slight_smile:

    Regards,

    Nithin

  • Konstantinos Xenos
    • Rubber Duck Debugger

    Hi Jason ,

    Even though the system backups that I had setup for you were working it seems that they don’t anymore as you correctly mention. In general the backup process is something that requires resources and from your last ticket you replied that the hosting company informed you of reaching memory limits.

    For a system backup to fail that’s most likely to happen actually either a memory or an I/O limit to be hit. Since these are server-side limits we don’t have access on that part to alter them and see if any raised limits might work for you.

    We do make updates in Snapshot constantly for it to be able to use as low server resources as possible but that depends on the site and server itself.

    Could you ask the hosting provider if there’s a chance to raise those limits so we can re-check if the backups finish properly?

    Regards,

    Konstantinos

  • Jason
    • Flash Drive

    Konstantinos,

    Dreamhost confirms that there are no I/O limits, and max_execution for PHP processes is set to 1500. The agent said some nonspecific error was killing the PHP processes and he increased the memory limit to correct it. But I tried running a Snapshot and as usual, it returned an error at 96% of plugins, 37% overall:

    [Wed Mar 13 08:53:54 2019] [error] [client 184.153.53.86] Premature end of script headers: admin-ajax.php, referer: http://jasonkaufman.com/wp-admin/admin.php?page=snapshot_pro_snapshots&snapshot-action=new&snapshot-noonce-field=b1a561da17

    He says that the server killed the process because it’s using too much CPU. The limit is set by Dreamhost and the specific PHP process that runs the backup/snapshot is using more CPU than the user is allowed on the shared server. He says that the limit has always been there, so it must be that the Snapshot tool was modified to use more memory, but I pointed out that Updraft fails also.

    I am having Dreamhost do a backup of my entire account that I can download, but this is not a solution. I need Snapshot and Backup to work smoothly.

    I have received offers to have WPMU act as my host for no extra charge. I am paid up with Dreamhost for the next year, but if moving to WPMU would solve the problem, I would consider it. Please advise.

    One more thing, he recommends that I start using PHP version 7.1 or 7.2, because 5.6 and 7.0 have been deprecated. How would I make that change?

    Jason

  • Konstantinos Xenos
    • Rubber Duck Debugger

    Thanks for the extra information Jason ,

    Please bear with me as this is going to be a lengthy reply so I can answer everything :slight_smile: .

    Let me clarify first that Snapshots + Managed Backups are using different method of creating backups, in any case though as I mentioned that’s why I was testing by utilizing the “system backups” so the server runs with it’s own limitations so that shouldn’t be breaking in my opinion.

    Snapshot hasn’t changed since the last time I’ve checked your ticket so it’s process should still be the same, the only thing that is let’s say “constantly” changing is the website itself since more content is added most likely so the backups get bigger as well. Again though by utilizing the system backup it shouldn’t be making any difference.

    I can’t speak for DreamHost or have full knowledge around their systems & servers to know how they work so I can explain things around that matter.

    As for PHP they are correctly recommending to use 7.x and to be more precise 7.1 wouldn’t be the best option either, you should go for 7.2+ versions as 7.1 is only getting security fixes for the time being. We are only giving 7.2 and 7.3 options ourselves on WPMU DEV Hosting since those are the actively current supported versions. As to “how you could make that change” there should be an option in your server admin area to change the PHP version at any point. PHP 7 is way more faster/secure than it’s previous versions and you should be making that change regardless the hosting environment that you’ll choose :slight_smile: .

    You can easily see PHP’s support at http://php.net/supported-versions.php .

    Our hosting provides nightly incremental backups and we retain them for 30 days, that practically means that the server itself is backing up everything ( files + database ) every day automatically and you can use the same system to make extra “manual” backups if you like within a day. There’s really no need to be using a plugin within WordPress this way and you can have a peace of mind as the server itself takes care of everything. You are still free to use a backup plugin if you like as well but that’s up to you.

    You can read more about our backups at https://premium.wpmudev.org/docs/hosting/backups/ and check out the whole WPMU DEV Hosting plans at https://premium.wpmudev.org/hosting/ .

    If you like I can help you further by creating a hosting environment for you and migrating your website there. You can keep it with the temporary domain for starters to see if everything works out for you, to see the backup system and other various tools that we’re offering and if everything is good you can point your domain there at any time to start fully using it.

    If you’d like me to help out on changing the PHP version or migrating your website over to our hosting I’d need access to your current server panel.

    You can send me the information needed privately through our contact form at https://premium.wpmudev.org/contact/#i-have-a-different-question by following this example:

    Subject: "Attn: Konstantinos Xenos"

    - Server Admin ( CPanel / Plesk )
    Username:
    Password:
    Login URL:

    - Link back to this thread for reference
    - Any other relevant URLs -or- information regarding the issue that was not included in this thread

    Tell me if you have any further questions or if I could help in any way mentioned above.

    Regards,

    Konstantinos

  • Jason
    • Flash Drive

    Konstantinos,

    I have added very very little data to the site — a handful of PDFs and photos — so that cannot be the reason for the Snapshot and Backup failures. As to moving to WPMU hosting, I believe Dreamhost also does regular backups, so that’s not a great benefit. I want WPMU plugins to work with my site, because I have been paying monthly for the privilege and it has only cost me a lot of time and aggravation. And it still is not resolved. Also, I do not want to switch to WPMU hosting if I will have to pay anything extra. If my site and traffic fall within the free Bronze category, I could consider it. However, I would like the update to the latest PHP 7.3, as long as the site will run properly.

    Thank you,

    Jason

  • Konstantinos Xenos
    • Rubber Duck Debugger

    Jason ,

    I’ve asked our Developers to take a further look as well just in case there’s something I’m missing here and they will reply as soon as possible.

    As for the PHP version as I’ve mentioned on my last reply the option should be somewhere in your Server Admin panel ( I can’t be sure were exactly I don’t have access there and I’m not very familiar with their admin areas ), maybe this article from Dreamhost can help https://help.dreamhost.com/hc/en-us/articles/214895317-How-do-I-change-the-PHP-version-of-my-site- . If that option is not available you can always ask them to change it for you.

    Regards,

    Konstantinos

  • Leonidas
    • Developer

    Hi there Jason ,

    I took a look at managed backups for your site and indeed the system backups that were previously working, don’t manage to complete anymore.

    That’s why I removed the system backup define and added the following in your wp-config:

    define('SNAPSHOT_TABLESET_CHUNK_SIZE', 75);
    define( 'SNAPSHOT_FORCE_ZIP_LIBRARY', 'archive' );
    // define('SNAPSHOT_ATTEMPT_SYSTEM_BACKUP', true);

    which basically instructs Snapshot to use its default engine with a smaller backup chunk size for the db part of the backup in order to bypass any memory/CPU issues originating from host limits. After those tweaks, I ran a managed backup which was completed and uploaded to the Hub successfully.

    That being said, it sounds like there are some hard limits on your hosting, which means that if the site grows significantly, it can again cause hiccups in the backup process again, so that’s something to monitor for the future.

    Best regards,

    Leonidas

Thank NAME, for their help.

Let NAME know exactly why they deserved these points.

Gift a custom amount of points.