Friday, August 28, 2009

Howto Change Mysql root Password and Users password

Some users want to change their mysql root password and users password.
mysqladmin

To setup root password for mysql in first time, use the following command :

$ mysqladmin -u root password NEWPASSWORD

If you want to change existing root password, then use following command

$ mysqladmin -u root -p oldpassword newpassword


For Changing MySQL user password

eg: for changing password for user panayara

$ mysqladmin -u panayara -p oldpassword newpass


No comments: