Monday, October 9, 2017

Re: Access denied for MySQL user in Django

Hi,
as far as i understood cdraccess  is a DB gust user, right?

If so, from your DB admin user, grant cdraccess to access MySQL environment table 'mysql.user' as follow:
 
GRANT SELECT ON `mysql`.`user` TO 'user_gui'@'%';

To me it worked,
Ivan

On Monday, January 25, 2016 at 7:52:33 PM UTC+1, James Schneider wrote:

And I get the usual error message:

(1045, u"Access denied for user 'cdraccess'@'77.95.177.35' (using password: NO)")

I have print statements and everything looks correct. It is printed as it is in the settings.py file.

One thing I noticed is that the IP 77.95.177.35 is my machine's IP, NOT the host's IP. For some reason the host IP (as it is given in the settings.py file) is replaced in this error message by my machine's IP. Is that normal?


Another thought. Do you manage the server/MySQL instance? Have you looked at the logs for MySQL to ensure that the password is the only issue? It's possible you are getting access denied for a number of reasons, including the database not existing when Django tries to access it.

-James

 

--
You received this message because you are subscribed to the Google Groups "Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to django-users+unsubscribe@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at https://groups.google.com/group/django-users.
To view this discussion on the web visit https://groups.google.com/d/msgid/django-users/e44f3710-d693-4f37-8a03-9eff7aebd258%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

No comments:

Post a Comment