I'm trying to access a MySQL database through mysqladmin. I have run into a huge headeache. Here's what I am doing:
C:\Program Files\MySQL\MySQL Server 4.1\bin\> mysqladmin [-u, -p] root my_password
After I send the command the system returns the following:
"mysqladmin: connect to server at 'localhost' failed
error: 'Access denied for user 'ODBC'@'localhost' (using password: YES)'"
Now I know I am using the correct password. If I do the following:
C:\Program Files\MySQL\MySQL Sever 4.1\bin\> mysql -u root -p
password: my_password
"Welcome to the MySQL monitor. Commands end with ; or \g.
Your MySQL connection id is 48 to server version: 4.1.10a-nt
Type 'help;' or '\h' for help. Type '\c' to clear the buffer.
mysql>"
Everything works okay. I believe the user accounts are set up okay. The following is what I get from "select user,host,password from user":
+-------+-----------------
------+---
----------
----------
----------
--+
| user | host | password |
+-------+-----------------
------+---
----------
----------
----------
--+
| root | localhost | encrypted_password |
| root | % | encrypted_password |
+-------+-----------------
------+---
----------
----------
----------
--+
As I understand this Windows uses the ODBC@localhost as the default username when none is specified. Yet, I am specifying using the root user account but it still doesn't work. I have also tried creating a user account called ODBC and that also produces the same error as above.
My setup is as above:
Windows XP Home SP1/SP2
MySQL Server VER 14.7 Distribution 4.1.10a
Thanks!
Start Free Trial