Wednesday, January 18, 2017

Oracle MySQL Server 5.6 installation

This post covers the high-level installation steps of Oracle MySQL Database server installation. download the required binaries from the below downloads link. In this post we are covering the installation of MySQL Community server 5.6 edition.

Downloads: https://www.mysql.com/downloads

Environment: RHEL/OEL 6
Documentation: https://dev.mysql.com/doc/refman/5.6/en/linux-installation-rpm.html

Steps:

  • Download the binaries from above specified location and save it in a temporary folder to extract

  • Extract the software using tar
    • tar -xvf MySQL-5.6.32-1.linux_glibc2.5.x86_64.rpm-bundle.tar
  • Below files are extracted as from the above command
 
  • Before starting the installation from the above files, run the below command to check if you have any existing MySQL instances running on this machine
    • rpm -qa | grep mysql
  •  Delete the existing instances as given below 
    • rpm -e mysql-libs-5.1.73-3.el6_5.x86_64 --nodeps           
  • Now it is clean to start installation procedure.
  • Install the binaries using the below rpm command as shown below. you might have to run this installation as root depending on your privileges
  • Each rpm package extracted will have its own purpose. please refer to provided mysql documentation link for more information on these packages. 
  • we are going to install the basic required packages that are mentioned below
    • rpm -ivh MySQL-server-5.6.35-1.linux_glibc2.5.x86_64.rpm
    • rpm -ivh MySQL-client-5.6.35-1.linux_glibc2.5.x86_64.rpm
    • rpm -ivh MySQL-devel-5.6.35-1.linux_glibc2.5.x86_64.rpm 
    • rpm -ivh MySQL-shared-compat-5.6.35-1.linux_glibc2.5.x86_64.rpm
 
 
  • Installation sets random password that is stored in the file that is highlighted above.
  • Install the remaining rpm packages with the similar command as shown below
 
  • Now the installation procedure is completed and you can start the MySQL server