binary files loaded with MySQL

Source: Internet
Author: User

Recently through the binary file installed MySQL to do some summary.

1. Download the binary package

wget http://mirrors.sohu.com/mysql/MySQL-5.6/mysql-5.6.32-linux-glibc2.5-i686.tar.gz

2. Unpacking the Package

Tar zxvf mysql-5.6.32-linux-glibc2.5-i686.tar.gz

3. Move the package to/usr/loacl/mysql

MV Mysql-5.6.32-linux-glibc2.5-i686/usr/local/mysql

4. Create a MySQL user

Useradd-s/sbin/nologin MySQL

5. Enter the/usr/mysql directory

cd/usr/local/mysql/

6. Create MySQL Data Catalog

Mkdir-p/data/mysql

7. Add the owning Master

Chown-r Mysql:mysql/data/mysql

8. Initializing the database

./scripts/mysql_install_db--user=mysql--datadir=/data/mysql

See two OK instructions initialization complete

9. Copy boot profile to/etc/init.d/mysqld and config file to/etc/mysql

CP Support-files/mysql.server/etc/init.d/mysqld

CP SUPPORT-FILES/MY-LARGE.CNF/ETC/MY.CNF

10. Give execution permission

chmod 755/etc/init.d/mysqld

11. Add or change the following configuration in/ETC/MYSQL.CNF

[Client]

Port = 3306

Socket =/tmp/mysql.sock


[Mysqld]


Basedir =/usr/local/mysql

DataDir =/data/mysql

Port = 3306

server_id = 1

Socket =/tmp/mysql.sock

Pid-file=/data/mysql/mysql.pid

12. Add MySQL to startup item

Chkconfig--add mysqld

Chkconfig mysqld on

Start MySQL

Service mysqld Start

Check if MySQL is started

Ps-aux|grep MySQL


This article is from the "My Linux Learning Journey" blog, so be sure to keep this source http://dousi.blog.51cto.com/9827926/1855923

binary files loaded with MySQL

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.