2

I get the error #1045 - Access denied for user 'root'@'localhost' (using password: NO) after I accidentaly changed the password in phpmyadmin for root and 127.0.0.1 . the problem is i cannot change common.lib.php. I want to revert these changes in mysql somehow... Doe to the security of the server i cannot change much

OMG Ponies
  • 300,587
  • 73
  • 490
  • 482
ka_lin
  • 8,596
  • 5
  • 31
  • 50

3 Answers3

3

I hope you can access the mysql server administration. As I know the root is the main user in MySQL it'll be a problem if you cannot access it. If you have a user with the same level, try to change the password there if possible.

Here's the step on how to reset the root password in MySQL

I was also dependent in phpmyadmin before until I know sqlyog and MySQL Query Browser and WorkBench. Have a look on this as an alternative on phpmyadmin.

ace
  • 6,507
  • 7
  • 36
  • 46
1

It's been a while since I've used phpMyAdmin, but if I'm not mistaken, it stores it's passwords in the mysql database it self. So, if you are able to get access to the command-line of the server, you are able to change the password using simple SQL statements.

DIJ
  • 197
  • 2
  • 18
  • I have done this, using the command line i have added in mysql.users user 127.0.0.1 with all priviliages, and killed a process and it worked like a charm. The problem was that I couldn`t stop XAMPP, and couldn`t edit any files of XAMPP (the default ones at least), and I couldn`t kill the processes, and restart wasn`t an option...complicated. And i couldn`t install anything... Admin Rights on server :| – ka_lin Apr 14 '11 at 12:32
0

Go to /etc/phpmyadmin folder. Open config-db.php

Here you will find your default username and password

krishnazden
  • 859
  • 8
  • 14