centos 下修改mysql 密码

PLEASE REMEMBER TO SET A PASSWORD FOR THE MySQL root USER !
To do so, start the server, then issue the following commands:
/usr/bin/mysqladmin -u root password 'new-password'
/usr/bin/mysqladmin -u root -h centos-svr password 'new-password'
Alternatively you can run:
/usr/bin/mysql_secure_installation

你可能感兴趣的:(centos)