Welcome Guest. Please Login or Register  


You are here: Index > AMPPS > General Support > Topic : phpmyadmin #1045 error



Threaded Mode | Print  

 phpmyadmin #1045 error, Can't connect to mysql (9 Replies, Read 5566 times)
schoujar
Group: Member
Post Group: Newbie
Posts: 18
Status:
Hi guys,

Getting the error shown in the attached image.

#1045 - Access denied for user 'root'@'localhost' (using password: YES)

I've tried a whole bunch of solutions found online. Nothing seems to work. :/

Thanks,

Sahil
IP: --   

phpmyadmin #1045 error
tidus
Group: Member
Post Group: Super Member
Posts: 1121
Status:
Hi,

Can you confirm few things ?

1. Is AMPPS apache running ?

Run the following command in terminal and let us know the output:
Code
ps aux | grep httpd


2. Have you changed mysql root password and edited the config.inc.php ? The file attached is different from the one which is provided in Ampps.

What is the path of config.inc.php ?


-----------------------
Follow AMPPS on,
Twitter : https://twitter.com/AMPPS_Stack
Facebook :  http://www.facebook.com/softaculousampps
Google+ : https://plus.google.com/+AmppsStack
IP: --   

phpmyadmin #1045 error
schoujar
Group: Member
Post Group: Newbie
Posts: 18
Status:
Yes Apache is running.
SQL is running.

But phpmyadmin is giving me this error out of the blue.

IP: --   

phpmyadmin #1045 error
tidus
Group: Member
Post Group: Super Member
Posts: 1121
Status:
Hi,

Are you able to connect using this command in terminal ?

Code
/Applications/AMPPS/mysql/bin/mysql -u root -pmysql



-----------------------
Follow AMPPS on,
Twitter : https://twitter.com/AMPPS_Stack
Facebook :  http://www.facebook.com/softaculousampps
Google+ : https://plus.google.com/+AmppsStack
IP: --   

phpmyadmin #1045 error
schoujar
Group: Member
Post Group: Newbie
Posts: 18
Status:
No, access denied. :(
I can connect with no password but then it doesn't show any databases

IP: --   

phpmyadmin #1045 error
jigar
Group: Member
Post Group: Newbie
Posts: 27
Status:
Hi,

Looks like mysql root password has been changed. Have you changed it ?
IP: --   

phpmyadmin #1045 error
schoujar
Group: Member
Post Group: Newbie
Posts: 18
Status:
No, I don't remember changing it.
I do remember, this problem occurring once before and I found some process of firing up mySQL in safe mode, skipping the grant tables and resetting the password.

BUT I can't seem to find that link again. :/

Any pointers folks?

IP: --   

phpmyadmin #1045 error
tidus
Group: Member
Post Group: Super Member
Posts: 1121
Status:
Hi,

Stop the MySQL server.

Code
/Applications/AMPPS/mysql/bin/mysqld --basedir=/Applications/AMPPS/mysql --datadir=/Applications/AMPPS/var --user=$USER --skip-grant-tables


Note: please confirm "echo $USER" is same user as the username given in the output of "ls -lha /Applications/AMPPS/var", if its not same please replace $USER with current user.

Open new Terminal and type:

Code
/Applications/AMPPS/mysql/bin/mysqladmin -u root password mysql


Your password is now set to "mysql"

Close MySQL:
Code
killall mysqld


Start MySQL now from Ampps.


Edited by tidus : December 27, 2013, 12:50 pm

-----------------------
Follow AMPPS on,
Twitter : https://twitter.com/AMPPS_Stack
Facebook :  http://www.facebook.com/softaculousampps
Google+ : https://plus.google.com/+AmppsStack
IP: --   

phpmyadmin #1045 error
schoujar
Group: Member
Post Group: Newbie
Posts: 18
Status:
Nope. Terminal just throws out a bunch of errors.

Thanks for all your help Tidus, I think a re-install is in order.
IP: --   

phpmyadmin #1045 error
tidus
Group: Member
Post Group: Super Member
Posts: 1121
Status:
Hi,

Let me know if it was resolved after a re-install.


-----------------------
Follow AMPPS on,
Twitter : https://twitter.com/AMPPS_Stack
Facebook :  http://www.facebook.com/softaculousampps
Google+ : https://plus.google.com/+AmppsStack
IP: --   

« Previous    Next »

Threaded Mode | Print  



Jump To :


Users viewing this topic
1 guests, 0 users.


All times are GMT. The time now is May 22, 2024, 11:12 am.

  Powered By AEF 1.0.8 © 2007-2008 Electron Inc.Queries: 11  |  Page Created In:0.031