On Fri, Feb 17, 2012 at 4:31 PM, Dennis Lee Bieber <[email protected]> wrote: > On Thu, 16 Feb 2012 18:55:14 -0800 (PST), Ishmael <[email protected]> > wrote: > > >>_mysql_exceptions.OperationalError: (1044, "Access denied for user >>'myuser'@'%' to database 'Mydatabase'") >> >>My settings file contains: >> >>DATABASES = { >> 'HOST': 'my.url.com', # Set to empty >>string for localhost. Not used with sqlite3. > >> 'PORT': '3306', # Set to empty string for >>default. Not used with sqlite3. >> } >>} >> >>How do I get rid of the '%' percent symbol for the local hostname? >> > One -- you aren't using "localhost" to connect. Is MySQL's port open > to connections asking for "my.url.com". That is, rather than connecting > to (localhost, MySQLPort) you are connecting via (my.url.com, > MySQLPort). {BTW: you may also be caught be another twitch -- about a > quarter way down http://dev.mysql.com/doc/refman/5.0/en/connecting.html > """ > On Unix, MySQL programs treat the host name localhost specially, in a > way that is likely different from what you expect compared to other > network-based programs. For connections to localhost, MySQL programs > attempt to connect to the local server by using a Unix socket file. > """ > > > Second -- if the port is open, have you added your user/password to > the NON-localhost account table (% is the wildcard for connecting host > address). The local tools are using localhost, not "my.url.com" to > connect.
I have no real insight on why the OP is getting this error message, but I would imagine the fact that they are getting an error response back from the server probably indicates that they are connecting ok to the server process. Cheers Tom -- You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send email to [email protected]. To unsubscribe from this group, send email to [email protected]. For more options, visit this group at http://groups.google.com/group/django-users?hl=en.

