Thursday, February 5, 2015

Solving the mySQL “The security settings could not be applied” error

Yesterday I got this error message during the last step of the MySQL Windows installer: “The security settings could not be applied to the database because the connection has failed with the following error”.

The issue can be solved issue this procedure from the MySQL website.

First, cancel the wizard and make sure that the MySQL service is stopped.

Then, create a text file using a SQL query that will reset the root password.

1
2
UPDATE mysql.user SET Password=PASSWORD('admin') WHERE User='root';
FLUSH PRIVILEGES;

Then, launch mySQL using the following command line:

1
mysqld --defaults-file="C:\Program Files\MySQL\MySQL Server 5.5\my.ini" --init-file="C:\mysql-init.txt" --console

Note: it’s better to use the ”–console” option so that error messages are correctly displayed.

Finally, open a new DOS shell and execute the following command line to shutdown mySQL:

1
mysqladmin -u root -p shutdown

You can now restart the mySQL installer and choose the “Repair” option:


No comments:

Post a Comment