Sigin or Register
Prosition: Home    >   Mysql   >  

ubuntu修改mysql默认密码

/etc/init.d/mysql stop

Then update the user table

mysqld –skip-grant-tables –skip-networking &

mysql mysql

UPDATE user SET password=PASSWORD(’yourrootpassword’) WHERE User=”root” AND Host=”localhost”;

quit

/etc/init.d/mysql restart