MySQL Forums
Forum List  »  Newbie

Re: MySQL Error Number 1045 Access denied
Posted by: Richard Mushene
Date: December 22, 2009 04:23AM

Hi all,

I will assume you have installed MySql on a Linux box. Then you have installed MySql Administrator on a Windows based machine, hence the 1045 Access denied Error.

I had the same problem and this is what i did.


Seems to me most of you haven't set the user up in mysql for access from that Windows machine. MySQL authenticates users based on Host and Username, not just username.

I don't know how your network or your server is set up so I would suggest the easiest way for you to set up this remote access is to create a user on the mysql server for remote access.

To do this log into your mysql server as root (or whatever your admin user is).
mysql -u root -p


Issue the statement....

GRANT ALL on *.* to 'new_user'@'192.168.22.10' IDENTIFIED BY 'new_user_password';


Replace dbname.tablename with the database and table names you need to access (USE *.* if you need access to all databases and tables)

Replace new_user with the chosen username.

Replace password with the chosen password.

If you want this user to be able to connect from any machine on your network replace 192.168.22.10 with 192.168.0.% or if you want to be able to connect from any location replace 192.168.0.34 with just a % but consider the security issues.

Hope this helps.

Regards
Richard Mushene
Linux Administrator

Options: ReplyQuote


Subject
Written By
Posted
Re: MySQL Error Number 1045 Access denied
December 22, 2009 04:23AM
March 06, 2007 11:22PM
February 20, 2008 06:17AM
August 04, 2009 09:05PM
December 15, 2005 12:56AM
March 03, 2009 11:07PM


Sorry, you can't reply to this topic. It has been closed.

Content reproduced on this site is the property of the respective copyright holders. It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.