Updating from WordPress 4.9.26 to 6.8 ?
-
Hello,
We want to update our (old) website to a newer wordpress version, and we wanted to know whether it was possible to update from 4.9.26 to 6.8. We see an option to upgrade to 6.8 on wordpress dashboard under the Update section, however we are skeptical if it is possible to update to the latest version from such old version, without breaking the website or losing any data. Could you please suggest us the best way to update to the lastest version ?
Thank you,
Marius Le Chapelier
The page I need help with: [log in to see the link]
-
You should be able to update all in one go. Many people choose to do it in stages anyway. Doing so requires downloading older versions and installing the files manually. When you first enter the backend after a manual update, WP will update the DB if it’s called for.
Either way, it’s imperative that you make a full backup of your site. It’s very unusual for an update to loose any data, but better safe than sorry. It’s not unheard of for an update to fail. No data is lost, but regaining functionality can in some rare cases be difficult. I recommend you become familiar with uploading files to your server via FTP. It’s a good skill to have in any case. With such knowledge, recovery from a mishap becomes much easier.
One reason for failure in the past had been due to server time outs. WP now attempts to increase time out allowance to avoid this. The belt and braces approach is to also manually set an extended time out in wp-config.php by inserting this line:
@ini_set('max_execution_time', 300 ); //in seconds, default is 30
After updating, you should remove the line or make it into a PHP comment by adding//to the head of the line.I would be careful with a direct update, but this is not directly related to WordPress. My recommendations:
- Create a backup before you do anything.
- Consider whether you want to perform the update in a test or staging system first. This ensures that you don’t make the live system inaccessible or break it as a result of the update. In a test/staging system, you can let off steam without your visitors noticing. There are many ways to create one. The easiest way is to use https://wordpress.org/plugins/wp-staging/ or your hoster will provide you with an option for this.
- Check which hosting conditions you currently have. Pay particular attention to the PHP version. If you are still using PHP 7.1 or older, you will probably not be able to run the current PHP 6.8. My recommendation would be to use at least PHP 7.4 for the update period. As soon as the update is complete, you can switch to PHP 8.2.
- Now it gets even more complicated: take a look at what plugins you have. There are many plugins that have not been updated. These are probably not compatible with PHP 7.4 or newer. This could lead to real problems when updating. If in doubt, deactivate the plugins, carry out the update and then test which ones still work after the update.
- The challenge with the plugins also exists with the theme you are using. Here too, you should check how old it is, whether there are any updates at all and if not, you can switch to an older standard theme for the update and then see whether your theme still works somehow.
That’s just a rough recommendation. Depending on how your project is structured, you may have to look at what you could lose or have to replace with this update. A staging system is always recommended for these big steps.
And always make backups 🙂
Hello,
Thanks for the advices and guidelines.
As you suggested, I tried to install the wp-staging plugin to be able to perform the update on a clone of the website not the website itself, but I get this error :
Installing Plugin: WP STAGING WordPress Backup Plugin – Migration Backup Restore 4.1.3Downloading installation package from https://downloads.wordpress.org/plugin/wp-staging.4.1.3.zip…Download failed. stream_socket_client(): SSL operation failed with code 1. OpenSSL Error messages: error:1416F086:SSL routines:tls_process_server_certificate:certificate verify failed stream_socket_client(): Failed to enable crypto stream_socket_client(): unable to connect to ssl://downloads.wordpress.org:443 (Unknown error)
Also, I am very new to these issues and I am not sure how to find the php version we are currently using from the WP dashboard, could you explain to me ?I am not too woried about the plugins because we are not using many, but the theme will probably be more problematic because we are using our own and I am not sure of its compatibility with newer versions… How can I check it’s compatibility if the cloning website and performing the update method with wp-staging doesn’t work ?
Thanks again,
Marius Le Chapelier
The error message indicates that your hosting cannot talk to the WordPress repository. You should contact your host’s support team, as only they can resolve this. However, it may also be related to an ancient PHP version that also uses ancient SSL libraries, which is why you cannot reach the repository to install plugins.
You can also install plugins manually. To do this, go to the plugin page mentioned above and click on the download button. You can upload the ZIP file manually in the backend under Plugins and install and activate the plugin this way.
You can find the PHP version currently used by your WordPress in the backend under Tools > Site Health. There you will also find any anomalies that may exist. The above-mentioned problem will probably also be listed there, although I’m not entirely sure due to the age of your WordPress.
Hello Again,
While trying to update the WordPress version to 6.8, I got the following error :
Update WordPress
Downloading update from http://downloads.wordpress.org/release/wordpress-6.8-new-bundled.zip…
Download failed.: stream_socket_client(): SSL operation failed with code 1. OpenSSL Error messages: error:1416F086:SSL routines:tls_process_server_certificate:certificate verify failed stream_socket_client(): Failed to enable crypto stream_socket_client(): unable to connect to ssl://downloads.wordpress.org:443 (Unknown error)
Installation FailedIt seems like it is not even able to download the package of the 6.8 version, due to some SSL error. Do you have any idea how to solve this ?
Marius Le Chapelier
I have already written the reason for this message in the answer above. The solution would be to install it manually. See also: https://wordpress.org/documentation/article/updating-wordpress/#manual-update
The topic ‘Updating from WordPress 4.9.26 to 6.8 ?’ is closed to new replies.