Locked out of mysql

Problems with the Windows version of XAMPP, questions, comments, and anything related.

Locked out of mysql

Postby fulmont99 » 05. April 2007 16:20

Hi All,

I am currently trying to use java with my mysql database. I tried running a program and I dont know what it did but now I cannot log into mysql. It says incorrect password. Is their a way to reset the admin password?

Thanks a million
Michael
fulmont99
 
Posts: 6
Joined: 05. April 2007 16:14

Postby Wiedmann » 05. April 2007 16:22

but now I cannot log into mysql.

You try to login with which program?
Wiedmann
AF Moderator
 
Posts: 17106
Joined: 01. February 2004 12:38
Location: Stuttgart / Germany

Postby fulmont99 » 05. April 2007 16:31

Wiedmann wrote:
but now I cannot log into mysql.

You try to login with which program?


Im trying to log in using phpadmin in xampp. None of the localhost sites I have created now work. Its strange because the java code I have written should just log into mysql. even it cannot get in anymore. The sites use php btw.

Thanks again,
Michael
fulmont99
 
Posts: 6
Joined: 05. April 2007 16:14

Postby Wiedmann » 05. April 2007 16:44

Im trying to log in using phpadmin in xampp.

error message?
Wiedmann
AF Moderator
 
Posts: 17106
Joined: 01. February 2004 12:38
Location: Stuttgart / Germany

Postby fulmont99 » 05. April 2007 16:56

Error
Cannot log in to the MySQL server

At the logon screen. Maybe it has wrecked the database and it is not the password at all. All of the databases are still in the data file. Its confusing me what could have happened.

web sites display

Warning: mysql_connect() [function.mysql-connect]: Access denied for user 'root'@'localhost' (using password: YES) in C:\Program Files\xampp\htdocs\Project\database.php on line 6
Access denied for user 'root'@'localhost' (using password: YES)

java says

java.sql.SQLException: Access denied for user 'root'@'localhost' (using password: NO)
at com.mysql.jdbc.SQLError.createSQLException(SQLError.java:946)
at com.mysql.jdbc.MysqlIO.checkErrorPacket(MysqlIO.java:2941)
at com.mysql.jdbc.MysqlIO.checkErrorPacket(MysqlIO.java:868)
at com.mysql.jdbc.MysqlIO.secureAuth411(MysqlIO.java:3340)
at com.mysql.jdbc.MysqlIO.doHandshake(MysqlIO.java:1238)
at com.mysql.jdbc.Connection.createNewIO(Connection.java:2743)
at com.mysql.jdbc.Connection.<init>(Connection.java:1553)
at com.mysql.jdbc.NonRegisteringDriver.connect(NonRegisteringDriver.java:266)
at java.sql.DriverManager.getConnection(DriverManager.java:525)
at java.sql.DriverManager.getConnection(DriverManager.java:171)
at Jdbc11.main(Jdbc11.java:23)


Michael
Last edited by fulmont99 on 05. April 2007 16:59, edited 1 time in total.
fulmont99
 
Posts: 6
Joined: 05. April 2007 16:14

Postby Wiedmann » 05. April 2007 16:59

Does the login work, if you use no password for the user "root"?
Wiedmann
AF Moderator
 
Posts: 17106
Joined: 01. February 2004 12:38
Location: Stuttgart / Germany

Postby fulmont99 » 05. April 2007 17:00

Wiedmann wrote:Does the login work, if you use no password for the user "root"?


Nope it says the same thing?
fulmont99
 
Posts: 6
Joined: 05. April 2007 16:14

Postby Wiedmann » 05. April 2007 17:19

Nope it says the same thing

That's not possible. Without an password the (complete) error message must be an other in your own script.
Instead:
Access denied for user 'root'@'localhost' (using password: YES)

It must be:
Access denied for user 'root'@'localhost' (using password: NO)
Wiedmann
AF Moderator
 
Posts: 17106
Joined: 01. February 2004 12:38
Location: Stuttgart / Germany

Postby fulmont99 » 05. April 2007 17:31

Sorry man, i thought you meant the logon to phpadmin:)

Anyway the result if i remove the password from the php is


Warning: mysql_connect() [function.mysql-connect]: Access denied for user 'root'@'localhost' (using password: NO) in C:\Program Files\xampp\htdocs\Project\database.php on line 6
Access denied for user 'root'@'localhost' (using password: NO)

Any ideas?

MM
fulmont99
 
Posts: 6
Joined: 05. April 2007 16:14

Postby Wiedmann » 05. April 2007 17:35

Wiedmann
AF Moderator
 
Posts: 17106
Joined: 01. February 2004 12:38
Location: Stuttgart / Germany

Postby fulmont99 » 05. April 2007 18:11

Hi, I tried changing the password a number of ways and logging in but it still is not working, is it possible the java program has done something to the database?

Thanks again for your time,
Michael
fulmont99
 
Posts: 6
Joined: 05. April 2007 16:14


Return to XAMPP for Windows

Who is online

Users browsing this forum: No registered users and 47 guests