1 / 2

How To Upgrade WordPress To MySQL 8 on CentOS?

How To Upgrade WordPress To MySQL 8 on CentOS?

audian9xo9
Download Presentation

How To Upgrade WordPress To MySQL 8 on CentOS?

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. How To Upgrade WordPress To MySQL 8 on CentOS? Today, we will talk about how to upgrade WordPress to MySQL 8. This is something that anyone can do who is responsible for managing the server. If we looked at the MySQL 8 update notes, we would see that updating from a version older than 5.7. x is not supported and is not an option. We prefer to trust the MySQL team on this and not risk updating directly. The steps for upgrading from 5.7 to 8.0 are similar in many ways, so we'll just briefly describe them, except for a few caveats that you $1 Hosting will need to pay attention to. We will discuss this in detail below, which leaves us with the following plan: • Prepare to upgrade to the latest version 5.7. x • Update to the latest version 5.7. x • Check the integrity of the database • Prepare to upgrade to the latest version 8.0. x • Update to the latest version 8.0. x • Fix the connection to the WordPress database • Check the database integrity So let's just get right to it and don’t forget moving up $1 Hosting CA for quick help. Step 1. Prepare to upgrade to the latest version 5.7. x Make a backup copy of your database In our case, we chose cold backup over the traditional sqldump approach. For cold backups, all you need to do is carefully complete the MySQL server process and copy its data directory to a secure location: $ sudo systemctl stop mysqld $ sudo tar zcvf /backup/mysql-cold-backup.20191115.001.tar.gz /var/lib/mysql It produces a very good .tar archive.gz of everything that MySQL stores in its storage. And this backup can be restored by simply unpacking this archive back to the MySQL data directory and you better look for $1 Web Hosting Australia for better hosting plan. Get the repository package update We always recommend using the official repositories to retrieve package updates. In the case of MySQL you need to go to http://repo.mysql.com/ and go to the package managers (yum in our case). Where will you find the release package that will add the repository to the server: $ sudo yum remove mysql-community-release

  2. $ sudo yum install http://repo.mysql.com/yum/mysql-5.7-community/el/7/x86_64/mysql57-community-release- el7-10.noarch.rpm $ sudo yum makecache Note that the first command is remove, a previously added MySQL release repository. If you didn't add it via the package Manager, you can skip this command. Now you have everything ready for the update process Step 2. Update MySQL to 5.7. x Make an update Udating the packages themselves is just as trivial: $ sudo systemctl stop mysqld $ sudo yum update mysql-community-server mysql-community-client Data transfer We have noticed that many people come across the fact that they also need to migrate data from old versions to new ones! Without data migration, your database may be corrupted. In the case of updates 5.6 - > 5.7, we can transfer data without starting the server. This is done using: $ sudo mysql_upgrade -u root -p In General, data migration should run smoothly in most cases (if we follow the recommendations of the MySQL team here). This was done for us, but if you came across some error messages during this process, please let us know in the comments. If looking for hosting services, do check Wordpress Hosting UK for saving a lot. Step 3. Check the database integrity Now we can launch our recently updated database. If all of the above was done without any error messages, then this should just work: $ sudo systemctl start mysqld For a more thorough check, you can just check the status of your website if WordPress can connect and doesn't show any errors – we are all ready for this stage and can proceed to upgrade to MySQL 8.

More Related