Oracle Linux 6.4 and MySQL 5.6

Oracle Linux had a lot of engineering hours inside it to drive the performance to new levels. But currently oracle Linux 6.4 comes with a dated version of MySQL, version 5.1.69. So how can you upgrade to 5.6 without losing your data?

First, make a backup just in case Murphy’s Law has a tort waiting for you.

Remove the old files. The rpm -qa | grep -i ^mysql command will show you the packages to be removed. Then rpm -e mysql-server-5.1.69-1.el6_4.x85_64 mysql-libs-5.1.69-1.el6_4.x86_64 and mysql-5.1.69-1.el6_4.x85_64 to remove them.

Thirdly, download the big MySQL 5.6 bundle for Oracle Linux. Untar the bundle and then a quick rpm -Uhv MySQL-*.rpm will install the files.

There is ONE big difference. MySQL as of 5.6, forces a default for the MySQL server and places it in /root/.mysql_secret and you will see to set a new password upon login as the assigned password is marked ‘expired’. Start up MySQL (/etc/init.d/mysql start) and use SET PASSWORD to change the password (unless you really like the password randomly generated you find in /root/.mysql and want to keep it.

Go double check you data just to make certain all is well.

And please note by using a status command (\s) that the charactersets may have changed. Under 5.1 the default is all Latin1. With 5.6, the server and Database charactersets are Latin1 while the client and the Connection character sets are Utf-8. Do not mix and match as somewhere in the to and frow, your data will be truned to useless goo. So stick with ALL Latin1 if you can, or force everything in your configuration files do use Utf8.

Note teh charactersets sets change from all Latin1 as the defualt to a mixture of Utf8 and Latin1!! Make sure it is all one character set or have your data cursed so it will turn into goo!

Note the charactersets sets change from all Latin1 as the defualt for 5.1 to a mixture of Utf8 and Latin1 for 5.6!! Make sure it is all one character set or have your data cursed so it will turn into goo!

So now we have MySQL 5.6 on the fastest Linux and it is time to get busy with them!


9 Responses to Oracle Linux 6.4 and MySQL 5.6

  1. eroomydna says:

    Dave, you skipped 5.5 upgrade. Is this status quo?

  2. forces a default “password”.
    places in /root/.mysql_secret not /root/.mysql

    I would also suggest that there are several configuration option changes, so be aware if you want to restore an old MySQL 5.1 config file if you use in production.

  3. You didn’t run mysql_upgrade! For example FULLTEXT indexes with tables that use ucs2 (or a few other charsets) need rebuilt with the QUICK option.

    Or did you expect them to dump/restore then check data? You forgot that step if so.

    There are config changes, like –log-slow-queries being deprecated which can cause problems too. And changes to important settings like innodb_old_blocks_time.

    You will get warnings about timestamp changes in your error log.

    Users should VERY CAREFULLY examine the upgrade document and note all INCOMPATIBLE CHANGE notifications before doing an upgrade. To just dump RPM files, and upgrade and not have a full plan in place is not good advice. User should set up a 5.6 instance, and a 5.1 instance as slaves of the 5.1 instance, use START SLAVE UNTIL to move them to the same location, then compare the results of queries. This is easy to do with pt-upgrade.

  4. […] Read the original post:  Oracle Linux 6.4 and MySQL 5.6 | Open Source DBA's Blog […]

  5. Can we expect MySQL 5.6/5.7 to be added to next updates of OracleLinux?

    • OpenSorceDBA says:

      Oracle Linux needs to track Redhat and offer the same software versions. But MySQL will make it as easy as possible to drop in 5.6/5.7 to keep you supplied with the latest and greatest version.

  6. When will Oracle provide a yum repository for MySQL packaged rpms?

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )


Connecting to %s

%d bloggers like this: