Home > Database > Mysql Tutorial > Detailed explanation of Linux using binary method to install mysql

Detailed explanation of Linux using binary method to install mysql

小云云
Release: 2017-12-22 14:39:13
Original
1522 people have browsed it

This article mainly introduces in detail the steps to install mysql in Linux using binary method. It has certain reference value. Interested friends can refer to it. I hope it can help everyone.

1. Download the binary file

Download mysql-5.6.36-linux-glibc2.5-i686.tar.gz.

2 on the official website. Unzip the file and Move to the /usr/local/mysql directory


tar -zxvf mysql-5.6.36-linux-glibc2.5-i686.tar.gz
Copy after login

3, create user groups and users and configure


groupadd mysql
useradd mysql -g mysql
chown -R mysql /usr/local/mysql/
chgrp -R mysql /usr/local/mysql/
Copy after login

4. Installation and initialization


#安装mysql
/usr/local/mysql/scripts/mysql_install_db --user=root
#配置mysql启动文件
cp /usr/local/mysql/support-files/my-default.cnf /etc/my.cnf
#将mysqld服务添加到系统中
cp /usr/local/mysql/share/mysql/mysql.server /etc/init.d/mysqld
#将mysql命令软链接到系统命令中
ln -s /usr/local/mysql/bin/mysql /usr/bin/mysql
Copy after login

5. Start service test


service mysqld start
mysql -u root
Copy after login

Related recommendations:

MySQL Binary Log(Binary Log)

Example of binary search method binarySearch in Java data structure

Graphic tutorial for installing MySQL5.6 in Linux environment

The above is the detailed content of Detailed explanation of Linux using binary method to install mysql. For more information, please follow other related articles on the PHP Chinese website!

Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template