Upgrade mysql version
This would probably make sense on Amazon EC2 instance where it comes by default with
mysql 5.5, as of this writing, and you want to upgrade mysql to the next version.
In this example I have used version 5.5 for the upgrade mysql example. But, technically the methodology would work for other versions as well unless mysql drastically changes folder locations.
How to upgrade mysql from 5.5 to 5.6
First go ahead and move the mysql 5.5 to new folder
sudo mv /var/lib/mysql /var/lib/mysql55
Then grab the tar from mysql download page [Here]
Once you download the tar file containing the new mysql version do the following commands on your terminal.
sudo tar -xvf yourDownloadedTar.tar
sudo rpm -ivh MySQL-shared-5.6.17-1.el6.x86_64.rpm
sudo rpm -ivh MySQL-client-5.6.17-1.el6.x86_64.rpm
sudo rpm -ivh MySQL-server-5.6.17-1.el6.x86_64.rpm
This would upgrade your current mysql version to mysql 5.6 or which ever is the new mysql version.
Then restart mysql for the change to take effect.