Set the Root Password

After installing MySQL, the first thing you’ll want to do is reset the root password for MySQL. You can achieve this using the following command:

[root@myhost]# mysqladmin -u root password new-password

Set MySQL to start automatically with the following command

[root@myhost]# /sbin/chkconfig mysqld on

Update:
A much better way to secure your installation of MySQL is to run the mysql_secure_installation command. This prompts you to set or change the root password, remove guest access and test databases, etc.

If you enjoyed this post, please consider to leave a comment or subscribe to the feed and get future articles delivered to your feed reader.

Comments

No comments yet.

Leave a comment

(required)

(required)