MySQL change root password

To change the root password for the database in linux you use mysqladmin utility. The parameters you need to pass are:
-u root the username used for logging in. In this case we want to be root obviously
-p'currentPassword' the password for logging in. Notice there are no space between p and quote.
password newPassword define the new password.

So for example:
mysqladmin -u root -p'myoldpassword' password mynewpassword

Comments

Popular posts from this blog

How many water molecules are there in the glass of water?

What does http-equiv stands for?