Reputation: 21
Using mysqldump on windows(2003-server - MariaDB) produces following error:
mysqldump: Got error: 1045: "Access denied for user 'ODBC'@'localhost' (using password: YES)" when trying to connect
Commands I used:
mysqldump --user=root --password=password -h127.0.0.1 --port=3306 database > backup.sql
mysqldump -uroot -ppassword database > backup.sql
mysqldump -uroot -p(enter password on promt) database > backup.sql
mysqldump -u root -p password database > backup.sql
mysqldump -u root -ppassword database > backup.sql
Etc, anything I used, same error popped up. Looks like some default-hardcoded user/password is used. I can connect to mysql -uroot -p just fine.
Internets have seen this error before, but I have not seen proper solution to this or I am oblivios to something.
Any insight would be amazing. Thanks.
Upvotes: 1
Views: 1409
Reputation: 11716
Double check your -
char in your commands. Sometimes copy&paste produces a different hyphen char.
Your command below should work:
mysqldump -u root -ppassword database > backup.sql
Upvotes: 1