Blogging software WordPress has had a built-in auto-update feature that downloads the latest files and updates itself with a single click, since version 2.7.
Sometimes, the auto upgrade functionality does not work, no matter how many times you try. In some cases, the update fails silently and the site continues to work, but the worst case scenario (which I have been at the receiving end of) is that the site is broken and pages are no longer accessible. To prevent this, it is important that you take every precaution possible.
1. Check permissions of folders
Make sure that all WP folders (wp-admin, wp-includes, wp-content, wp-content/upgrade etc.) and files have the necessary permissions.
WordPress root directory, wp-admin, wp-includes, wp-content/plugins – writable only by your user account.
wp-content – writable by all
wp-content/themes – group writable to use theme editor, writable only by your user account if not using it
Not sure if this is necessary, but I usually make wp-content/upgrade and wp-content writable by all for the update, then change back the permissions after upgrade.
2. Clear wp-content/upgrade folder
The upgrade folder might have leftover files from previous failed updates.
3. Deactivate plugins
Forgetting to deactivate plugins is a frequent problem for me. To make things easier, create a checklist for upgrades – you can use steps from this article itself.
More fixes will be added here when I discover them. If you have any suggestions, please write a comment to let me know.