• Resolved iannnn

    (@iannnn)


    Hi

    I’ve spent my Sunday trying to find a way to restore “Others”. Database, plugins, themes, uploads all restore ok. Unfortunately “others” does not.

    Error message:

    0000.436 () PHP event: code E_WARNING: copy(): The first argument to copy() function cannot be a directory (line 281, wp-admin/includes/class-wp-filesystem-direct.php)
    0000.519 () Error message: Could not move old files out of the way. You should check the file ownerships and permissions in your WordPress installation (/home/[I deleted this reference for privacy]/public_html/assets/mu-plugins-old)
    0000.520 () Restore failed…
    0000.520 () Error message: Could not move old files out of the way. You should check the file ownerships and permissions in your WordPress installation (/home/[I deleted this reference for privacy]/public_html/assets/mu-plugins-old)
    0000.520 () Restore failed

    In my cPanel mu-plugins-old have 775 permission. Can anyone think of any thing else that is causing this issue?

    I’ve downloaded the “others” backup data to my PC and can see the mu-plugins-old folder (along with mu-plugins-old-old). Would there be any risk of deleting these folders manually on my PC before uploading to cPanel as a zip file?

    Any ideas are welcome.

    Thank you,
    Ian

Viewing 4 replies - 1 through 4 (of 4 total)
  • Plugin Contributor bcrodua

    (@bcrodua)

    Hi,

    It appears to be a file permission/ownership issue, meaning UpdraftPlus or WordPress does not have the correct read or write permission to a certain folder or file.

    The following article on Smashing Magazine is a good guide as to the file permissions/ownerships that are required for WordPress: https://www.smashingmagazine.com/2014/05/proper-wordpress-filesystem-permissions-ownerships/#file-and-folder-ownership-for-wordpress

    Regards,
    Bryle

    Thread Starter iannnn

    (@iannnn)

    Thanks for the quick reply bcrodua. I’ve set my file permissions to 775 but this doesn’t seem to help. Do you have any other ideas?

    Also, could I ask: what do the -old and -old-old files represent?

    Thank you,
    Ian

    Plugin Contributor bcrodua

    (@bcrodua)

    Hi Ian,

    Alternatively, you can restore the others.zip component manually and then just restore the rest of the components as normal or through UpdraftPlus restoration. To manually restore, just simply extract the file and upload to “wp-content” folder.

    Regards,
    Bryle

    Thread Starter iannnn

    (@iannnn)

    Thanks brcroua, have found the cause of the issue, I have a manual workaround but its not ideal.

    If I restore “Others”, there are folders that are added in my wp-content folder with “-old” added at the end. UpdraftPlus and GoDaddy don’t seem to be able to work together to remove the “-old” folders from wp-content following a restoration (even though I may have either 755 or 775 permissions).

    If I try to restore whilst there are “-old” folders in either my live site’s wp-content OR the backup’s wp-content then the restoration fails.

    If I am going to create a backup in future I will have to ensure (through FTP or cPanel) that I have no “-old” or “-old-old” folders in wp-content before carrying out the backup, if there are any I’ll have to manually delete them in FTP/cPanel. I’ll also have to keep regularly checking my weekly backups that are automatically carried out by UpdraftPlus to ensure they don’t contain “-old” folders.
    I’m also going to have to ensure that if I ever restore “Others” that there are no “-old” or “-old-old” folders in the wp-content of my live site through FTP/cPanel.

    UpdraftPlus and GoDaddy work ok when restoring plugins (a “Delete Old Directories” button pops up which allows the plugins restoration to work on the 2nd attempt) and themes etc. For some frustrating reason “Others” just doesn’t seem to have be able to remove the “-old” folders it is creating during the restoration.

    Any questions let me know,
    Thanks
    Ian

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘Please help – “Could not move old files out of the way”’ is closed to new replies.