CentOS Install MySQL

Source: Internet
Author: User
Tags mysql client

Environment and Resources

PC System: Centos 6.5 32-bit

MySQL Server 5.6

URL: http://cdn.mysql.com//Downloads/MySQL-5.6/MySQL-server-5.6.27-1.el6.i686.rpm

MySQL Client 5.6

URL:http://cdn.mysql.com//Downloads/MySQL-5.6/MySQL-client-5.6.27-1.el6.i686.rpm

See if MySQL is installed

#rpm-qa | grep MySQL

If there is, force delete

#rpm-E--nodeps mysql-libs-5.1.73-5.el6_6.i686

Install MySQL

1) Download MySQL server and MySQL Client

#wget http://cdn.mysql.com//Downloads/MySQL-5.6/MySQL-server-5.6.27-1.el6.i686.rpm

#wget http://cdn.mysql.com//Downloads/MySQL-5.6/MySQL-client-5.6.27-1.el6.i686.rpm

2) Unzip

#rpm-IVH mysql-server-5.6.27-1.e16.i686.rpm

#rpm-IVH mysql-client-5.6.27-1.e16.i686.rpm

Note: If the following error occurs

Workaround:

#yum Install libaio.so.1 libnuma.so.1


Using MySQL

1) After installing the default profile in/usr/share/mysql/my-default.cnf, copy the my-default.cnf to/ETC/MY.CNF

#cp/usr/share/mysql/my-default.cnf/etc/my.cnf

2) Start MySQL

#/etc/init.d/mysql start

3) MySQL Client connection

#mysql-uroot

Workaround: (Modify root user password)

/etc/init.d/mysql Stop (service mysqld stop)
/usr/bin/mysqld_safe--skip-grant-tables
also open an SSH connection
[[email protected] ~]# MySQL
mysql>use MySQL
mysql>update User Set Password=password ("") where user= "root";
Mysql>flush privileges;
Mysql>exit

4) Use the MySQL client connection again

#/etc/init.d/mysql start (start MySQL service)

#mysql-uroot


CentOS Install MySQL

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.