Server Fault is a question and answer site for system and network administrators. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I recently installed phpMyAdmin with MySQL, it works fine, allows the root to login via the website, but when I attempt to create users and give assign them to a database, it gives me the error "#1045 Cannot log in to the MySQL server". This server is running on CentOS 5.8.

share|improve this question

Ensure the credentials in the phpMyAdmin configuration are correct and that it is pointed at the correct server. You may also check your mysql logs (possibly in the system logger but generally /var/log/mysql/mysqld.err and /var/log/mysql/mysqld.log) to see what happens when you try to do anything in phpMyAdmin.

Remember that phpMyAdmin's login is separate from the mysql login.

share|improve this answer
I deleted the mysqld.log and then tried to login again, nothing changed, still getting #1045 Cannot log in to the MySQL server – nd8ad Apr 13 '12 at 8:49
I didn't mean that deleting the logs would help; I meant that more information on the error would be contained in them. – Falcon Momot Jun 26 '13 at 5:00

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.