二进制安装MySQL-安装

1、系统环境初始化

yum install libaio autoconf -y

groupadd mysql

useradd -r -g mysql -s

/usr/sbin/nologin -M mysql

2、安装

上传安装包到/usr/local/src目录

cd /usr/local/src

tar xfmysql-5.6.35-linux-glibc2.5-x86_64.tar.gz

mv mysql-5.6.35-linux-glibc2.5-x86_64../mysql-5.6.35

ln -s /usr/local/mysql-5.6.35//usr/local/mysql

cd /usr/local/mysql

chown -R mysql.mysql .

\cpsupport-files/my-default.cnf /etc/my.cnf

scripts/mysql_install_db –user=mysql

chown -R root.root .

chown -R mysql.mysql ./data

./bin/mysqld_safe &

你可能感兴趣的:(二进制安装MySQL-安装)