Snapshot times out at around 62%

When you try to create a backup using Snapshot ("Snapshot -> Snapshots") it times out. This happens around 62% in general and 90% of plugins backup progress. That is, with "default" snapshot created (there should be a WPMU TEST one that can be used for testing).

  • James Morris

    Hello Alejandro,

    I hope you are well today. I'll be following up with you regarding your chat.

    I've logged into your site and server and I found your PHP configuration was very restrictive. You were only set to use 64M in memory_limit and your max_execution_time was set to 150. Even though these values were change in wp-config.php, this does not override the PHP configuration. I've added a .user.ini file to the root of your site in public_html with the following values:

    memory_limit = 1024M
    upload_max_filesize = 64M
    post_max_size = 64M
    max_input_time = 600
    max_execution_time = 600

    I also updated your wp-config.php with the following to force WordPress to make use of the available memory:

    define('WP_MEMORY_LIMIT', '1024M');

    I then performed a backup using the WPMU DEV Test Snapshot. It still failed at the same point.

    I'm flagging this issue for our SLS Team so they can dig into this issue deeper to determine why, with so much resources available, the Snapshots are failing. They will update this ticket once more information is available.

    Best regards,

    James Morris

  • Lindeni Mahlalela

    Hello Alejandro

    I hope you are doing great today. I am sorry for the delayed response from our side and I hope we work together to resolve this.

    As I was looking into this issue I have noticed that the FTP Login is not working. When I try to login to your SFTP I get the following error in FileZilla:

    Error:	Received unexpected end-of-file from SFTP server
    Error:	Could not connect to server

    And the following in WinSCP:

    Cannot initialize SFTP protocol. Is the host running an SFTP server?

    Would you please check with your host if there is anything wrong with the FTP server or double check the login detail. If you have updated the login details you can share new ones via our secure contact form, on the contact form choose "I have a different question", in the subject line write "Attn: Lindeni Mahlalela" then in the message box include:

    - New FTP login details (FTP Host, Port, Username and Password)
    - Link back to this thread for reference

    Once we have this will will continue to investigate the issue. I will also keep trying with the login details I have, maybe there is a temporal issue on the server.

    I hope to hear back from you soon.

    Have a nice day.
    Mahlamusa

  • Lindeni Mahlalela

    Hello Alejandro

    I hope you are doing great today. Thank you for your patience while we were looking into this issue.

    I have looked at the issue again and I have found that Snapshot was timing out due to a low value set for max_execution_time. The process fails when processing the uploads/2016/06 folder which seems to contain more files than other directories and it seems that some images in this folder are much bigger than regular website images which makes Snapshot take time to process this. It also seems to stall at the 'plugins' folder but it continues to run after some time.

    If I exclude the 'uploads/2016/06' Snapshot finishes without issues. To make things easier and to ensure the backups run smoothly, you may want to exclude this folder as well or create a backup that will only contain the media files and have the other files in the main backup that will include database, plugins and themes.

    In an attempt to solve this issue, I have modified the .user.ini file in the root of your install to increase the time limit in order to give snapshot more time to process. I have change the max_execution_time line to:

    max_execution_time = 1800

    And also modified the snapshot configs added in wp-config.php, I modified the constants to look like this:

    define('SNAPSHOT_FILESET_CHUNK_SIZE', 10);
    define('SNAPSHOT_TABLESET_CHUNK_SIZE', 100);
    define('SNAPSHOT_FILESET_LARGE_FILE_SIZE', 104857600); //~100MB
    if (!defined('SNAPSHOT_FORCE_ZIP_LIBRARY')) define('SNAPSHOT_FORCE_ZIP_LIBRARY', 'pclzip');
    if (!defined('SNAPSHOT_IGNORE_SYMLINKS')) define('SNAPSHOT_IGNORE_SYMLINKS', true);

    After these changes I tested Snapshot by regenerating the the Snapshots and also created a new one, it all seems to work as it should. I have also tested with the folder 'uploads/2016/06' NOT excluded and it seemed to work as well.

    Please test from your side and let me know what results you get.

    I hope this makes sense to you. Please let us know if you need any further assistance with regards to this.

    Have a nice day.
    Mahlamusa

Thank NAME, for their help.

Let NAME know exactly why they deserved these points.

Gift a custom amount of points.