Product:
Search Type:

Plesk installation fails with the error: "Access denied for user: 'root@localhost'".

Article ID: 228 
Last Review: Mar,30 2008
APPLIES TO:
  • Plesk for Linux/Unix

SYMPTOMS

Plesk installation fails with the error:


Trying to connect with admin:setup account... ERROR 1045: Access denied for user: 'admin@localhost' (Using password: YES)
not connected
Trying to connect as root with empty password... ERROR 1045: Access denied for user: 'root@localhost' (Using password: NO)
not connected Cannot connect to mysql database.



RESOLUTION

Normally for Plesk installation, MySQL administrator must be 'root' user with the empty password. If you know current 'root' MySQL password, please login with it and continue with the query from the step 2. If you do not know the password, begin from the step 1:

1.Add the 'skip-grant-tables' option into /etc/my.cnf in '[mysqld]' section and restart MySQL:

2. Set the empty password for MySQL 'root' user:
# mysql -uroot -Dmysql -e 'update user set password="" where user="root"'

3. Comment out or remove string 'skip-grant-tables' in /etc/my.cnf and restart MySQL.

4. Try to install Plesk again.

Also see the article about Plesk admin password recovery.

Please provide feedback on this article

Did this article help you solve your issue?
Yes
No
Partially
I do not know yet
 
Strongly Agree   Strongly Disagree
  9 8 7 6 5 4 3 2 1
The article is easy to understand
The article is accurate
Additional Comments:
*Please provide us with your email address in case we need to contact you.
*Please type the code you can see.
* - required fields