Did You Know?
Ask a Question

We are pleased to announce the Launch of our New Section "TecMint Ask"

Install MySQL 5.5.30 on RHEL/CentOS 6-5, Fedora 18-12

Download Your Free eBooks NOW - 10 Free Linux eBooks for Administrators

This how-to guide is to install or upgrade your MySQL version on RHEL/CentOS 6-5 and Fedora 18,17/16/15/14/13/12 using Remi repository via YUM utility. But before moving into further steps let’s understand little bit about MySQL.

What is MySQL?

MySQL is an open source free relational database management system (RDBMS) released under GNU (General Public License). It is used to run multiple databases on any single server by providing multi-user access to each created database.

Install MySQL 5 5 30

Install MySQL 5 5 30

Install MySQL 5.5.30 on RHEL 6-5, CentOS 6-5, and Fedora 18/17/16/15/14/13/12

Step 1: Installing Remi Repository

Firstly, we need to install the Remi repository on your selected Linux distributions.

For Fedora 18-12

## Install Remi Repository on Fedora 17, 16, 15
rpm -Uvh http://download1.rpmfusion.org/free/fedora/rpmfusion-free-release-stable.noarch.rpm 
rpm -Uvh http://download1.rpmfusion.org/nonfree/fedora/rpmfusion-nonfree-release-stable.noarch.rpm

## Fedora 18 ##
rpm -Uvh http://rpms.famillecollet.com/remi-release-18.rpm

## Fedora 17 ##
rpm -Uvh http://rpms.famillecollet.com/remi-release-17.rpm

## Fedora 16 ##
rpm -Uvh http://rpms.famillecollet.com/remi-release-16.rpm

## Fedora 15 ##
rpm -Uvh http://rpms.famillecollet.com/remi-release-15.rpm

## Fedora 14 ##
rpm -Uvh http://rpms.famillecollet.com/remi-release-14.rpm

## Fedora 13 ##
rpm -Uvh http://rpms.famillecollet.com/remi-release-13.rpm

## Fedora 12 ##
rpm -Uvh http://rpms.famillecollet.com/remi-release-12.rpm

For RHEL/CentOS 6-5

## Install Remi Repository on RHEL/CentOS 6.7-6.0 ##
rpm -Uvh http://download.fedoraproject.org/pub/epel/6/i386/epel-release-6-7.noarch.rpm
rpm -Uvh http://rpms.famillecollet.com/enterprise/remi-release-6.rpm 

## Install Remi Repository on RHEL/CentOS 5.4-5.0 ##
rpm -Uvh http://dl.fedoraproject.org/pub/epel/5/i386/epel-release-5-4.noarch.rpm
rpm -Uvh http://rpms.famillecollet.com/enterprise/remi-release-5.rpm

Step 2. Checking MySQL 5.5.30 Availability

After, installing Remi repository on your system, then look for MySQL latest version using –enablerepo=remi switch option.

# yum --enablerepo=remi list mysql mysql-server

Sample Output:

Available Packages
mysql.i686		5.5.30-1.el6.remi	remi
mysql-server.i686	5.5.30-1.el6.remi       remi

Step 3: Updating or Installing MySQL 5.5.30

Once you see the latest MySQL version is available for installation, then follow below steps to update or install MySQL 5.5.30.

# yum --enablerepo=remi install mysql mysql-server

Step 4: Starting/Stopping MySQL Server

Follow the below command to start/stop of the MySQL service.

# /etc/init.d/mysqld start
# /etc/init.d/mysqld stop
# /etc/init.d/mysqld status

Step 5: Connecting to MySQL Server

Connecting to newly installed MySQL server by providing username and password. If you haven’t yet set any password for your MySQL installation the simply hit enter.

# mysql -u root -p

Sample Output:

[root@twiki ~]# mysql -u root -p
Enter password:
Welcome to the MySQL monitor.  Commands end with ; or g.
Your MySQL connection id is 1052
Server version: 5.5.30 MySQL Community Server (GPL) by Remi

Copyright (c) 2000, 2011, Oracle and/or its affiliates. All rights reserved.

Oracle is a registered trademark of Oracle Corporation and/or its
affiliates. Other names may be trademarks of their respective
owners.

Type 'help;' or 'h' for help. Type 'c' to clear the current input statement.

mysql>

That’s it, you’ve successfully installed MySQL 5.5.30 on your system. If you’re having any trouble installing feel free to use our comment section for solutions.

Ravi Saive

Owner at TecMint.com
Simple Word a Computer Geek and Linux Guru who loves to share tricks and tips on Internet. Most Of My Servers runs on Open Source Platform called Linux.

Linux Services & Free WordPress Setup

Our post is simply ‘DIY’ aka ‘Do It Yourself, still you may find difficulties and want us to help you out. We offer wide range of Linux and Web Hosting Solutions at fair minimum rates. Please submit your orders by Clicking Here.

14 Responses

  1. hammam says:

    Hi there

    Thank you for the tutorial.

    However I have been having issues with following your steps and I am sure there is some thing missing on my OS.

    However I am trying to install it on Centos 5.8 x86_64 but this is what I get:

    [root@localhost ~]# yum –enablerepo=remi list mysql mysql-server
    Loaded plugins: fastestmirror, security
    Loading mirror speeds from cached hostfile
    * remi: remi-mirror.dedipower.com
    * rpmforge: archive.cs.uu.nl
    Available Packages
    mysql.x86_64 5.5.28-3.el5.remi remi
    mysql-server.x86_64 5.5.28-3.el5.remi remi
    [root@localhost ~]# yum –enablerepo=remi install mysql mysql-server
    Loaded plugins: fastestmirror, security
    Loading mirror speeds from cached hostfile
    * remi: remi-mirror.dedipower.com
    * rpmforge: archive.cs.uu.nl
    Setting up Install Process
    Resolving Dependencies
    –> Running transaction check
    —> Package mysql.x86_64 0:5.5.28-3.el5.remi set to be updated
    –> Processing Dependency: mysql-libs = 5.5.28-3.el5.remi for package: mysql
    —> Package mysql-server.x86_64 0:5.5.28-3.el5.remi set to be updated
    –> Processing Dependency: perl-DBI for package: mysql-server
    –> Processing Dependency: perl-DBD-MySQL for package: mysql-server
    –> Processing Dependency: perl(DBI) for package: mysql-server
    –> Running transaction check
    —> Package mysql-libs.x86_64 0:5.5.28-3.el5.remi set to be updated
    —> Package mysql-server.x86_64 0:5.5.28-3.el5.remi set to be updated
    –> Processing Dependency: perl-DBI for package: mysql-server
    –> Processing Dependency: perl-DBD-MySQL for package: mysql-server
    –> Processing Dependency: perl(DBI) for package: mysql-server
    –> Finished Dependency Resolution
    mysql-server-5.5.28-3.el5.remi.x86_64 from remi has depsolving problems
    –> Missing Dependency: perl(DBI) is needed by package mysql-server-5.5.28-3.el5.remi.x86_64 (remi)
    mysql-server-5.5.28-3.el5.remi.x86_64 from remi has depsolving problems
    –> Missing Dependency: perl-DBD-MySQL is needed by package mysql-server-5.5.28-3.el5.remi.x86_64 (remi)
    mysql-server-5.5.28-3.el5.remi.x86_64 from remi has depsolving problems
    –> Missing Dependency: perl-DBI is needed by package mysql-server-5.5.28-3.el5.remi.x86_64 (remi)
    Error: Missing Dependency: perl(DBI) is needed by package mysql-server-5.5.28-3.el5.remi.x86_64 (remi)
    Error: Missing Dependency: perl-DBI is needed by package mysql-server-5.5.28-3.el5.remi.x86_64 (remi)
    Error: Missing Dependency: perl-DBD-MySQL is needed by package mysql-server-5.5.28-3.el5.remi.x86_64 (remi)
    You could try using –skip-broken to work around the problem
    You could try running: package-cleanup –problems
    package-cleanup –dupes
    rpm -Va –nofiles –nodigest
    <<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<

    Could you please help me as I am in the middle of setting up my server but this is being a big obstacle in front of me.

    Thank you.

    • Ravi Saive says:

      @hammam,
      The following packages having some issue, please remove them first, and then try the command again.

      yum erase perl-DBD-MySQL mysql-libs
      

      I hope it will work, if you still getting errors, please post here

      • Bathakaraithangam says:

        @Ravi Saive,
        I am also got the same error message. When i erase and reinstall perl-DBD-MySQL (using yum install perl-DBD-MySQL command) i got

        -> yum –disablerepo=\* –enablerepo=remi install mysql mysql-server
        Loaded plugins: dellsysid, fastestmirror
        Loading mirror speeds from cached hostfile
        * remi: remi-mirror.dedipower.com
        Setting up Install Process
        Resolving Dependencies
        –> Running transaction check
        —> Package mysql.x86_64 0:5.5.30-1.el5.remi set to be updated
        –> Processing Dependency: mysql-libs = 5.5.30-1.el5.remi for package: mysql
        —> Package mysql-server.x86_64 0:5.5.30-1.el5.remi set to be updated
        –> Running transaction check
        —> Package mysql-libs.x86_64 0:5.5.30-1.el5.remi set to be updated
        –> Processing Conflict: mysql-server conflicts MySQL-server
        –> Processing Conflict: mysql conflicts MySQL
        –> Finished Dependency Resolution
        mysql-5.5.30-1.el5.remi.x86_64 from remi has depsolving problems
        –> mysql conflicts with MySQL-server-community
        mysql-server-5.5.30-1.el5.remi.x86_64 from remi has depsolving problems
        –> mysql-server conflicts with MySQL-server-community
        Error: mysql conflicts with MySQL-server-community
        Error: mysql-server conflicts with MySQL-server-community
        You could try using –skip-broken to work around the problem
        You could try running: package-cleanup –problems
        package-cleanup –dupes
        rpm -Va –nofiles –nodigest

        error message..

        • Ravi Saive says:

          Please remove the “MySQL-server-community” package with yum and try to run the command again. Let me know the output of the command after removing.

          • Bathakaraithangam says:

            Is there any other way other than removal of “MySQL-server-community” package. Because i am doing migration process of MySQL from 5.0 to 5.5. Please guide me other than uninstallation

          • Ravi Saive says:

            Alternatively, you can use “rpm -ev packagename” to uninstall packages. If you get dependency errors, use –nodeps option.

            # rpm -ev package-name
            OR
            # rpm -ev --nodeps package-name
            
  2. ITM7 says:

    Use:

    yum –enablerepo=remi,remi-test install mysql55 mysql55-server mysql55-*

    Thank you

  3. Aseem says:

    Pls suggest how to install mysql on RHEL

  4. sandeep says:

    Hi Mr. Ravi,
    I did a benchmark on two linux servers on amazon:

    Setup-1:
    OS: Amazon Linux AMI 2013.03.1
    MySql: 5.5.31 MySQL Community Server (GPL)
    Installed mysql simply by doing: yum install mysql55

    Setup-2:
    OS: Centos 6.3
    uname -a
    Linux 2.6.32-279.2.1.el6.centos.plus.x86_64 x86_64 GNU/Linux
    Mysql: default version 5.1
    Upgraded to 5.5.32 MySQL Community Server (GPL) by Remi

    In both setups I loaded two Mysql tables containing three int indexed fields with 55 Million records (MyIsam). And I ran a query that joins two tables and finds common rows.

    In Setup-1:
    First time run of the query took 200 sec.
    Second time run of same query took 3 sec.

    In Setup-2:
    First time run of the query took 2200 sec.
    Second time run of same query took 2200 sec.
    Tried more than 3 times and still taking 2200 sec to run.

    Note: Both setups have same hardware and Mysql settings.

    Now the question is “Why the performance is poor in remi update?”

    • Ravi Saive says:

      In First Setup, you’ve installed packages directly using default CentOS Base repo which is much faster, because it uses own CentOS servers to download. In Second Setup scenario, you using third party repository called Remi which of course slow, because its fetches packages from their servers, might they not much fast as CentOS does.

  5. clark rosal says:

    how to put password in mysql server? so that only root can acess it..thanks hoping for quick response..

Leave a Reply

© 2012-2013 All Rights Reserved.