标签:bash 博客 inux proc flush start lan 除了 image
/usr/local/mysql/data
目录下面有东西,删除了就好了E<OspCjN-0of
[root@k8s-master data]# cd /usr/local/mysql/bin
[root@k8s-master bin]# ./mysqld --initialize --user=mysql --datadir=/usr/local/mysql/data --basedir=/usr/local/mysql
[root@k8s-master bin]# service mysqld start
[root@k8s-master bin]# vim ~/.bash_profile
[root@k8s-master bin]# source ~/.bash_profile
#mysql
export PATH=$PATH:/usr/local/mysql/bin
[root@k8s-master bin]# mysql -u root -p
mysql> alter user user() identified by "密码";
mysql> flush privileges;
mysql> use mysql;
mysql> update user set user.Host=‘%‘ where user.User=‘root‘;
mysql> flush privileges;
标签:bash 博客 inux proc flush start lan 除了 image
原文地址:https://www.cnblogs.com/ruigege0000/p/13605269.html