If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

 
Go Back  dBforums > Database Server Software > MySQL > Error 1045 (28000):

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old 04-10-06, 09:33
Bek Bek is offline
Registered User
 
Join Date: May 2005
Posts: 5
Error 1045 (28000):

Hello,

A few days ago I bought a vserver. I was planing to use it for the mysql database.
When i login as root and trying to access mysql I get this error message.

ERROR 1045 (28000): Access denied for user 'root'@'localhost' (using password: NO)

I tried these commands

mysql -uroot -ppassword mysql

mysql -uroot -p'' mysql

but non of them works (same error) !

would be great if I can find support here.

reagards

Bek
Reply With Quote
  #2 (permalink)  
Old 04-10-06, 10:20
jfulton jfulton is offline
Registered User
 
Join Date: Apr 2005
Location: Baltimore, MD
Posts: 297
Make sure you're using the correct password. It shouldn't be a permissions issue if it is a clean install and you are connecting as root. Also, you don't need to specify a database to connect to. (And using the `mysql` database directly is generally a very bad idea...)
Code:
shell> mysql --user=user_name --password=your_password db_name
If you can't remember your password, reinstall it.
http://dev.mysql.com/doc/refman/5.0/en/mysql.html
Reply With Quote
  #3 (permalink)  
Old 04-10-06, 11:14
Bek Bek is offline
Registered User
 
Join Date: May 2005
Posts: 5
the password is 100% correct, do you have any other idea what i can do ?
Reply With Quote
  #4 (permalink)  
Old 04-10-06, 11:48
jfulton jfulton is offline
Registered User
 
Join Date: Apr 2005
Location: Baltimore, MD
Posts: 297
The (using password: NO) part of your error is telling you that either 1.) you are not entering a password, or 2.) you are trying to enter the password incorrectly. Just for kicks, try using the --user=user_name --password=your_password syntax.

Also, if you leave the password blank, and use
Code:
mysql -uroot -p mysql
it should prompt you for a password.

Last edited by jfulton; 04-10-06 at 11:53.
Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On