Forums

Access is denied, when opening Mysql console

Hello! After import database, Mysql server rejects my request with "Access denied for user" error. I tried to fix problem by "GRANT ALL PRIVILEGES", but now I'm getting the next error on console opening: Access denied

Those blocks my workd at all. What wrong, and how to fix it?

It looks like you have somehow managed to change your database password without updating the .my.cnf file that stores it so that MySQL consoles can be started without entering the password. The quickest way to fix that is to change the password from the "Databases" page -- that will change it both on the database server, and in .my.cnf.

Thank you for your answer! Tried to change password, but no effect've been made...

May be, any other options to resolve this issue?

What do you see in .my.cnf file in your home directory?

Oh, got it. Changed password according .my.cnf file and it works. However, went back to original exception in Python application: ProgrammingError(1142, (42000): SELECT command denied to user %user%; for table %table%;

That was original issue. Could you tell me please, what's wrong, and how to fix it?

What is the username and the table in the error message? Which database are you connected to? If there's private information in that, then you can contact us privately at support@pythonanywhere.com.

Sent it

Problem solved via email. Thanks

Great! Glad we could help.