Wamp phpMyAdmin - Forgotten or No Password - Locked Out

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

Wamp phpMyAdmin - Forgotten or No Password - Locked Out

Postby JAA17 » 25. September 2017 16:29

I have just used phpMyAdmin on my local machine for the first time in about 6 months. I am using localhost:8080. I thought I had no password, however when it asks me to log in I put:

username: root
password: [I leave this blank]


I cannot log in.

I do not think I created a new password 6 months ago, but there is a small possibility I did and have now forgotten about it.

So now I am locked out of my phpMyAdmin.

I have tried the solution here by RiggsFolly:

https://stackoverflow.com/questions/29070501/regaining-access-to-lost-mysql-password-for-phpmyadmin-on-wamp

But no luck.

I do the following:

Stop the mysql service

wampmanager -> MySQL -> Service -> Stop Service


Edit the my.ini file

wampmanager -> MySQL -> my.ini


Find the wampmysqld64 section in the ini file Add this line directly after that section heading

skip-grant-tables


Restart the mysql service.

wampmanager -> MySQL -> Service -> Start/Resume Service


Open the MySQL console

wampmanager -> MySQL -> MySQL Console


It asks for the password, but I just tap enter and it seems to skip that. I then get the MySQL> prompt.

I have version 5.7.9 so I enter the following:

UPDATE mysql.user SET authentication_string=PASSWORD('MyNewPass') WHERE User='root';


Sometimes it gives a warning, but I do not know what.

I should then do the following two commands now, but I get a problem:

ALTER USER 'root'@'localhost' PASSWORD EXPIRE NEVER;
FLUSH PRIVILEGES;


It says (after the ALTER USER bit):

ERROR 1290 (HY000): The MySQL server is running with the --skip-grant-tables option so it cannot execute this statement


If I do the obvious thing and stop the service as above and then alter the .ini file again to remove that line. I then restart and retype the ALTER USER 'root'@'localhost' PASSWORD EXPIRE NEVER; command. This time it complains saying I should have just done a password change to make this command. (It basically thinks I have not just done the password change as I have had to shut down the system, alter the ini file and then restart in between the commands.)

So I am stuck at this point getting nowhere fast.

If the ALTER USER 'root'@'localhost' PASSWORD EXPIRE NEVER; and FLUSH PRIVILEGES; had worked, I would have then have had to continue with the following:

At the console mysql> prompt I would then need to type:

quit;


Then stop the mysql service:

wampmanager -> MySQL -> Service -> Stop Service


Edit the my.ini file

wampmanager -> MySQL -> my.ini


Find the wampmysqld64 section in the ini file Remove the skip-grant-tables parameter we added earlier.

Restart the mysql service.

wampmanager -> MySQL -> Service -> Start/Resume Service


However, as I am stuck at those two commands with no workaround I remain locked out of phpMyAdmin

Please help.
JAA17
 
Posts: 1
Joined: 25. September 2017 16:22
XAMPP version: 2.4.17
Operating System: Windows 10

Re: Wamp phpMyAdmin - Forgotten or No Password - Locked Out

Postby Altrea » 25. September 2017 19:01

Hi,

You are totally wrong here. This here is the XAMPP support board, not the WAMPServer support board.

best wishes,
Altrea
We don't provide any support via personal channels like PM, email, Skype, TeamViewer!

It's like porn for programmers 8)
User avatar
Altrea
AF Moderator
 
Posts: 8942
Joined: 17. August 2009 13:05
XAMPP version: several
Operating System: Windows 10 Pro x64


Return to XAMPP for Windows

Who is online

Users browsing this forum: No registered users and 57 guests