[Snapshot Pro] Snapshot Managed Backup is not uploading archive to The Hub

After multiple issues with Snapshot and my webhost (https://premium.wpmudev.org/forums/topic/snapshot-managed-backup-didnt-run-as-configured#post-1307095) I am stuck with the last question of why the archives haven't been uploaded to the cloud yet and are only kept on my server.
It still might be some server side issues. I have only run 3 managed backups and that hardly is a big database to use for an argument. And all three of them were created during night time when the server issues have been showing up the most.

However, I've just been running multiple Managed Backups manually during daytime and all ended up locally on my server. But finishing with "Your backup has been successfully created and uploaded to WPMU DEV servers!"
I then went ahead and uninstalled WPMUDEV Dashboard and Snaphost. On reinstalling Dashboard nothing unusual happend. But when I reinstalled Snapshot I got "Server error status: error [503]" - which might explain the problem for uploading. But it also means that there's someting off in the way that Snapshot checks if the upload to the cloud was successful.

I have another (bigger) multisite install on the same host where scheduled managed Snaphots have been finishing every night without any incidents while this site here has been giving me issues. Of course that doesn't rule out that it's a server side issue but it does feel like the issue is more likely to be found inside the wordpress install.

I've enabled support access. Hope that gives you enough information to look into things.

Cheers,
Peter

  • Kasia Swiderska

    Hello Peter,

    Can you check on that other Multisite what are your current memory limits? You can find those in WPMU DEV -> Support -> System Info. On site where it is not working max_execution_time is only 50 - where best value is 150-180.
    If that value is different between sites (higher on site where it works) can you try increase value following this tutorial https://premium.wpmudev.org/blog/increase-memory-limit/

    If that is not the issue I would need to see more debug logs, because one in Managed Backup are not showing any errors regarding the upload to cloud.
    To enable debug log in WordPress, open your wp-config.php file and look for define(‘WP_DEBUG’, false);. Change it to:
    define('WP_DEBUG', true);
    In order to enable the error logging to a file on the server you need to add yet one more similar line:

    define( 'WP_DEBUG_LOG', true );

    In this case the errors will be saved to a debug.log log file inside the /wp-content/directory.

    Depending on whether you want your errors to be only logged or also displayed on the screen you should also have this line there, immediately after the line mentioned above:

    define( 'WP_DEBUG_DISPLAY', false );

    The wp-config.php is located in your WordPress root directory. It’s the same file where the database configuration settings are. You will have to access it by FTP or SFTP in order to edit it.

    I would need then to see content of the debug.log file - so please upload it to service like a Dropbox and paste link here.

    kind regards
    Kasia

  • Peter

    Hi Kasia,

    done some more testing over the last couple of days.

    1. max_execution_time=50 is the same in every environment I have tested on. So yes, not good - but:
    2. I migrated the problem install to another account where Snapshot cloud upload was working before. With even more data to transfer in the zip file: 180MB vs 130MB. Once I had migrated the upload issue occured on the former working domain. So this indicates it is inside the install somehere.
    3. I just tested Managed Backup on third domain on a new install: upload worked a charm. (Still with max_execution_time=50)
    4. Error Log. Only recorded event straigh after the upload fails:
    [19-Mar-2018 00:44:53 UTC] PHP Warning: set_time_limit(): Cannot set max execution time limit due to system policy in /wp-content/plugins/snapshot/lib/Snapshot/Model/Destination/aws/AWSSDKforPHP/lib/requestcore/requestcore.class.php on line 834
    [19-Mar-2018 00:44:53 UTC] PHP Warning: set_time_limit(): Cannot set max execution time limit due to system policy in /wp-content/plugins/snapshot/lib/Snapshot/Model/Destination/aws/AWSSDKforPHP/lib/requestcore/requestcore.class.php on line 834
    Which can't be the real reason or whole story behind the problem because of 1.-3.

    5. Only other event related to Snapshot in the debug log:
    [11-Mar-2018 22:24:22 UTC] PHP Fatal error: Uncaught Error: Call to undefined function ftp_connect() in /wp-content/plugins/snapshot/lib/Snapshot/Model/Destination/ftp/index.php:589
    Stack trace:
    #0 /wp-content/plugins/snapshot/lib/Snapshot/Model/Destination/ftp/index.php(75): SnapshotDestinationFTP->login()
    #1 /wp-includes/class-wp-hook.php(286): SnapshotDestinationFTP->destination_ajax_proc('')
    #2 /wp-includes/class-wp-hook.php(310): WP_Hook->apply_filters('', Array)
    #3 /wp-includes/plugin.php(453): WP_Hook->do_action(Array)
    #4 /wp-admin/admin-ajax.php(97): do_action('wp_ajax_snapsho...')
    #5 {main}
    Snapshot/Wordpress all the sudden requested ftp user name and pw. I have seen this in that install on some other occasions on page load when clicking on a link. While being logged in to admin. Not sure if that is in any way related to the failing upload. Usually all I get in debug.log is the message from 4. So 5. seems a little more like a freak coincidence - but there does seem to be something weird about this install on a very basic level. Maybe that is what is causing the failing upload after all somehow.

    Hope that helps.

    Cheers,
    Peter

  • Kasia Swiderska

    Hello Peter,

    I will need developer to take a closer look on this. Could you please send in the following via our secure contact form https://premium.wpmudev.org/contact/#i-have-a-different-question :

    - Mark to my attention, the subject line should contain only: ATTN: Kasia Swiderska
    - Do not include anything else in the subject line, doing so may delay our response due to how email filtering works.
    - Link back to this thread
    - Include WordPress network admin access details (login address, username & password)
    - Include FTP log-in details (hostname, username & password)
    - Include any relevant URLs for your site

    IMPORTANT: Please make sure you select "I have a different question" for your topic, so it doesn't go back to the forums - this and the subject line ensure that it gets assigned to me.

    Please confirm here that you send those credentials

    kind regards,
    Kasia

  • Peter

    Hi Kasia,

    I got completely lost in other things. Forgot all about this. I just checked the current snapshots - and it looks like for the past week the Snapshots ended up in the cloud and not on my server anymore.

    Not sure and I couldn't find any dates in the changelog for Snapshot Pro: has there been an update in the last week to 10 days?
    Also just noticed that all managed backups in the cloud have todays time stamp for "created" even though they seem to have the right order and individual "2 days ago", "3 days ago" and so on. I also get an error message on the Snapshot logo in the hub but no actual errors showing.

    Cheers,
    Peter

  • Kasia Swiderska

    Hello Peter,

    Not sure and I couldn't find any dates in the changelog for Snapshot Pro: has there been an update in the last week to 10 days?

    Actually yes, there were updates for Snapshot in April.

    Also just noticed that all managed backups in the cloud have todays time stamp for "created" even though they seem to have the right order and individual "2 days ago", "3 days ago" and so on.

    Oh, I can see the same. I'm reporting this to developers of HUB. It might be some glitch there after last update. They will check that and provide a fix.

    kind regards,
    Kasia

Thank NAME, for their help.

Let NAME know exactly why they deserved these points.

Gift a custom amount of points.