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 > Password? mysqldump?

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old 11-28-09, 10:20
01010011 01010011 is offline
Registered User
 
Join Date: Nov 2009
Posts: 4
Password? mysqldump?

Hello,
I'm having 2 problems using MySQL on my personal computer.

The first problem is, sometimes the command line client accepts my password, othertimes it does not. I am not sure what I am doing to cause this but I would like to avoid being lockout of my own databases.

The second problem concerns using mysqldump. When I am able to access my databases using my password, and I try to use mysqldump like this:

Quote:
mysqldump -u myUserName -p myDatabaseName > "C:\myDatabaseName.sql"
I get the following error message:

Quote:
mysqldump: Got error: 1045:Access denied for user 'myUserName'@localhost' (using password: YES) WHEN TRYING TO CONNECT
I have no idea what is going on. Any assistance will be appreciated. Thanks in advance.
Reply With Quote
  #2 (permalink)  
Old 11-29-09, 06:31
healdem healdem is offline
Jaded Developer
 
Join Date: Nov 2004
Location: out on a limb
Posts: 9,250
what permissions have been GRANTed to MyUsername.
you can review the permissions easily enough in MySQLAdministrator
__________________
I'd rather be riding my Versys or my Tiger 800 let alone the Norton
Reply With Quote
  #3 (permalink)  
Old 11-29-09, 13:54
01010011 01010011 is offline
Registered User
 
Join Date: Nov 2009
Posts: 4
Quote:
Originally Posted by healdem View Post
what permissions have been GRANTed to MyUsername.
you can review the permissions easily enough in MySQLAdministrator
Thank you for your reply healdem. I finally figured out the cause of my two problems:

1. Regarding my passwords not being accepted sometimes, the reason was the MySQL service was either uninstalled or the service was not running. So from now on I'll make sure the MySQL service is installed and running.

2. Regarding the mysqldump problem, I did not use the correct user name, which is root. So the correct commands in the Windows Command Prompt are as follows:

Quote:
mysqldump -u root -p databaseName > "C:\MySQLBackupFolder\databaseName.sql"
If after entering your password, nothing happens, then it worked.

I hope this helps anyone else who had the same problem!

Last edited by 01010011; 11-29-09 at 13:56. Reason: Typo
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