Cannot log in to phpMyAdmin with MariaDB root user

August 29, 2015 12k views
MariaDB LEMP Ubuntu

I have used the TuxLite scripts to setup my Ubuntu 14.04 server. All has been working fine for weeks until now.

I can not log in to phpMyAdmin with the root user. However other users previously created can still access their databases. However I can log in to MariaDB using the root user from the command line.

I'm not sure what I have done to cause this, or whether something changed when I ran my weekly apt-get update/upgrade.

Does anyone have any possible solutions to my problem?

4 Answers

Try to reset the root user's access. Run via command.

GRANT ALL PRIVILEGES ON *.* TO root@localhost IDENTIFIED BY ' your current password ' WITH GRANT 

Is that after logging in to MariaDB on the command line?

In the end I did a database dump, uninstalled MariaDB, cleared out all the data stores for the tables, and then reinstalled MariaDB, and imported the databases.

I then exported each database individually, and created a new user/database for each database using the MariaDB root account on phpMyAdmin. Once I had gone through all the databases and successfully reimported each the them and made sure that each one was working correctly, I took a DO snapshot of the server.

However once the server came back online, that was when the MariaDB root user stops being able to login through phpMyAdmin. I can still login to MariaDB using the commandline, but not through phpMyAdmin.

I even attempted to run the above command, but I still cannot login to MariaDB using root on phpMyAdmin.

Further thoughts?

Have another answer? Share your knowledge.