特性:
默认开启事件
调整了部分默认参数值
新增部分动态配置项
支持在线修改全局参数持久化
查询缓功能影响性能在8.0已经被剔除
innodb_buffer_pool_size内存参数自适应,运维无需对服务器内存进行分配。
卸载旧包:
rpm -e –nodeps mysql-community-libs-5.7.19-1.el6.x86_64
rpm -e –nodeps mysql-community-server-5.7.19-1.el6.x86_64
rpm -e –nodeps mysql-community-common-5.7.19-1.el6.x86_64
rpm -e –nodeps mysql-community-libs-compat-5.7.19-1.el6.x86_64
rpm -e –nodeps mysql-community-client-5.7.19-1.el6.x86_64
rpm -e –nodeps mysql-community-devel-5.7.19-1.el6.x86_64
安装依赖:
yum install cmake
yum install ncurses-devel
yum install bison
yum install git openssl-devel
yum -y install gcc gcc-c++ ncurses ncurses-devel cmake bison git openssl-devel
使用二进制包直接部署:
tar xf mysql-8.0.12-linux-glibc2.12-x86_64.tar.gz -C /usr/local/
mv /usr/local/mysql-8.0.12-linux-glibc2.12-x86_64/ /usr/local/mysql
groupadd mysql
useradd -d /usr/local/mysql -g mysql -s /sbin/nologin mysql
chown -R mysql:mysql /usr/local/mysql
cp /usr/local/mysql/support-files/mysql.server /etc/init.d/mysqld
chmod +x /etc/init.d/mysqld
mkdir /var/lib/mysql
chown mysql:mysql /var/lib/mysql
ln -s /tmp/mysql.sock /var/lib/mysql/mysql.sock
ln -s /usr/local/mysql/include/mysql /usr/include/mysql
ln -s /usr/local/mysql/lib/mysql /usr/lib64/mysql
ln -s /usr/local/mysql/bin/mysql /usr/bin/mysql
ln -s /usr/local/mysql/bin/mysqladmin /usr/bin/mysqladmin
ln -s /usr/local/mysql/bin/mysqldump /usr/bin/mysqldump
ln -s /usr/local/mysql/bin/myisamchk /usr/bin/myisamchk
ln -s /usr/local/mysql/bin/mysqld_safe /usr/bin/mysqld_safe
或者
echo “export PATH=$PATH:/usr/local/mysql/bin” >> /etc/profile
source /etc/profile
mkdir -p /data/mysql/data
chown -R mysql:mysql /data/mysql/
配置为空密码,方便后续直接修改:
/usr/local/mysql/bin/mysqld –user=mysql –datadir=/data/mysql/data –initialize-insecure
chkconfig –level 35 mysqld on
/etc/init.d/mysqld restart
修改密码策略/创建用户并授权:
mysql -uroot -e “alter user root@’localhost’ identified by ‘password’ password expire never;”
mysql -uroot -ppassword -e “flush privileges;”
mysql -uroot -ppassword -e “alter user root@’localhost’ identified with mysql_native_password by ‘password’;”
mysql -uroot -ppassword -e “create user root@’127.0.0.1′ identified with mysql_native_password by ‘password’;”
mysql -uroot -ppassword -e “grant all privileges on . to root@’127.0.0.1′ with grant option;”
mysql -uroot -ppassword -e “flush privileges;”
最新评论
世间因为有你而美丽!我也一直想当个志愿者,奈何身体不允许
告诉那小孩 叫哥哥
666
123
此时此刻,感慨万千,旧的一年已经过去,新的一年已经到来,展望未来,美好的日子正等 着我们去奋斗,愿在新的一年里,我们能够继续经受住考验,克服困难,春暖花开
智能插座都是扯,插座还是公牛好用
下载链接失效了 求补
连接失效了