解决方法不是百度一搜一大把的东西,别用百度。
详见官方文档 here
> cd /etc/rc.d/init.d
> vi mysql-init.txt
ALTER USER 'root'@'localhost' IDENTIFIED BY 'MyNewPass';
> ./mysql.server start --init-file=/etc/rc.d/init.d/mysql-init.txt
解决方法不是百度一搜一大把的东西,别用百度。
详见官方文档 here
> cd /etc/rc.d/init.d
> vi mysql-init.txt
ALTER USER 'root'@'localhost' IDENTIFIED BY 'MyNewPass';
> ./mysql.server start --init-file=/etc/rc.d/init.d/mysql-init.txt