• Skip to primary navigation
  • Skip to main content
  • Skip to primary sidebar
sharadchhetri

sharadchhetri

Tutorials On Linux, Unix & Open Source

  • Home
  • Linux Commands
  • Resources
    • Learn Linux
  • My WordPress plugins

Install MySQL Server 5.6 in CentOS 6.x and Red Hat 6.x Linux

December 26, 2013 by Sharad Chhetri 1 Comment

Install MySQL Server 5.6 in CentOS 6.x and Red Hat 6.x Linux

In this tutorial we will learn how to install MySQL Server 5.6 in CentOS 6.x and RHEL 6.x by using yum command.The package is “Architecture Independent” hence applicable to 32 bit(i386) and 64 bit(x86_64) operating system.

Details of system where practical has been applied

Operating System: CentOS 6.5
Arch: x86_64 and i386 (Both)


To install the MySQL server 5.6,follow the given below steps.


Step 1:
Login into the Server and download the yum repo rpm package.
(URL: http://dev.mysql.com/downloads/repo/)

yum install wget
wget http://repo.mysql.com/mysql-community-release-el6-5.noarch.rpm

Step 2: Now install the downloaded rpm package.


rpm -ivh mysql-community-release-el6-5.noarch.rpm

Step 3: Now install the mysql server by using yum command.
Note: The yum command by-default also install the dependencies


yum install mysql-server

Step 4: After installation start the mysql server


/etc/init.d/mysqld start

Other options:

Usage: /etc/init.d/mysqld {start|stop|status|restart|condrestart|try-restart|reload|force-reload}

Step 5: Because the MySQL server is just installed it has blank mysql root password. To reset the mysql root password.

You can use the given below command, and follow the instruction


mysql_secure_installation

You can also use the given below alternate method

Login into mysql server. Because it is freshly installed hence root password is blank

mysql -u root

After login you will get mysql propmt. Run the given commands (remove mysql> if you are doing copy paste these commands)

mysql> use mysql;
mysql> update user set password=PASSWORD("GIVE-NEW-ROOT-PASSWORD") where User='root';
mysql> flush privileges;
mysql> quit

Share this:

  • Twitter
  • Facebook
  • More
  • Print
  • Email
  • LinkedIn
  • Reddit
  • Tumblr
  • Pinterest
  • Pocket
  • Telegram
  • WhatsApp
  • Mastodon

Related posts:

  1. How to create multiple mysql instance in CentOS 6.4 and Red Hat 6.4
  2. Recover Linux Grub Password in linux rescue mode CentOS/Red Hat
  3. How to add/install Ubuntu fonts in CentOS/Red Hat Linux
  4. How to find when Operating system was installed in linux CentOS and Red Hat
  5. make command not found in linux CentOS Red Hat ubuntu Debian
  6. netstat command not found on CentOS 7 and RHEL 7 (Red Hat Enterprise Linux 7)
  7. Find mysql commands history without mysql server login
  8. How to install apache webserver in CentOS and Red Hat
  9. How to install whois client in CentOS and Red Hat
  10. Install Ubuntu font family for individual user in CentOS/Red Hat

Filed Under: Linux Tagged With: mysql

Reader Interactions

Comments

  1. Arup Ghosh says

    July 10, 2016 at 6:33 pm

    Thanks for the detailed tutorial.

    Reply

Leave a Reply Cancel reply

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

This site uses Akismet to reduce spam. Learn how your comment data is processed.

Primary Sidebar

Our Social Media Presence

  • Facebook
  • GitHub
  • Twitter

Linux Command

What is Linux Internal And External Command

Linux Basic Commands With Examples For Every Beginner

tr command to convert lines to space , tab and vertical tab

smbpasswd command not found on CentOS 7 and RHEL 7

Solution : semanage command not found

Unix / Linux : How to print duplicate lines from file

More Posts from this Category

You Might Like These Articles!

simplecodesyntax wordpress plugin

SimpleCodeSyntax : My Another WordPress Plugin

Install Nginx

How To Install Nginx On Ubuntu 22.04 LTS

Install Latest Git package in Ubuntu Operating System

How To Always Install Latest Git Package In Ubuntu Operating System

Bash script for installing VirtualBox on Ubuntu 22.04 LTS Desktop

Install VirtualBox On Ubuntu 22.04 LTS Desktop (Bash Script)

libfuse

dlopen(): error loading libfuse.so.2 – Got Error On Ubuntu

Failed to open/create the internal network

VirtualBox Error: Failed to open/create the internal network

Always Useful Tips And Tricks

How to zip the directory in linux with command line

How to protect from port scanning and smurf attack in Linux Server by iptables

send email after mysql backup through bash script in simple way

How to change hostname in Ubuntu 12.04 and 12.10 without system restart

shell-init: error retrieving current directory: getcwd: cannot access parent directories: No such file or directory

Convert hyphen to underscore in between all filenames shell script

How to create a file with cat command

Explore 90+ Article On "Linux Tips And Tricks"

Copyright © 2023 ยท
The material in this site cannot be republished either online or offline, without our permission.
Proudly Blogging From Bharat.

  • Contact
  • About Me
  • My WordPress plugins
  • Privacy Policy