How to install mysql5.1 and mysql5.5 in linux

How to install mysql5.1 and mysql5.5 in linux.

Question: How to install mysql 5.1. and mysql 5.5 in linux.

Answer: Using remi and webstat repository we can install mysql 5.1 and 5.5 in linux.

How to install mysql5.1 and mysql5.5 in linux.
Lets install mysql 5.1 in CentOS/Redhat linux

First we need to download remi repository using wget command. Then install remi repository rpm. Then install the required rpm packages using yum command.

Step 1: Download the remi repository rpm using following command.
wget http://rpms.famillecollet.com/enterprise/remi-release-5.rpm

Step 2: Install the remi repository rpm.
rpm -ivh remi-release-5.rpm

If it show some dependency error then fire below command
rpm -ivh remi-release-5.rpm –nodeps

Step 3: Check required mysql packages are available.
yum –enablerepo=remi  list all | grep mysql

Step 4: Install the required mysql5.1 packages.
yum –enablerepo=remi install mysql.i386  mysql-devel.i386  mysql-embedded.i386  mysql-embedded-devel.i386 mysql-libs.i386 mysql-server.i386 mysql-test.i386

Step 5: Verify the mysql version.
mysql -V

Finally mysql 5.1. is installed successfully.

Lets learn how to install mysql 5.5 in CentOS / Redhat operating system.

Installing mysql 5.5 is also same as like installing mysql 5.1. The only thing that differs is the repository server name.

First we need to download webtatic repository using wget command. Then install webtatic repository rpm. Then install the required rpm packages using yum command.

Step 1: Download the remi repository rpm using following command.
wget http://repo.webtatic.com/yum/centos/5/latest.rpm

Step 2: Install the remi repository rpm.
rpm -ivh latest.rpm

If it show some dependency error then fire below command
rpm -ivh latest.rpm –nodeps

Step 3: Check required mysql packages are available.                                            yum –enablerepo=webtatic list all | grep mysql55

Step 4: Install the required mysql5.5 packages.                                                      yum –enablerepo=webtatic install mysql55.i386  mysql55-bench.i386  mysql55-devel.i386  mysql55-embedded.i386  mysql55-embedded-devel.i386   mysql55-libs.i386  mysql55-server.i386  mysql55-test.i386

Step 5: Verify the mysql version.                                                                                 mysql -V




Leave a Reply

Your email address will not be published. Required fields are marked *