MySQL and PhpMyAdmin config.inc.php Password issue on MAMP - mysql

This is a very strange issue that is similar to a few other people issue that has been going on for a while with MAMP.
I recently upgraded to MAMP2 and followed the instruction for the new phpMyAdmin and it work for a while but recently whenever I try to connect to MySQL I always get this error:
Error: Could not connect to MySQL server!
/Applications/MAMP/Library/bin/mysqlcheck: Got error: 1045: Access denied for user 'root'#'localhost' (using password: YES) when trying to connect
So I changed the password to the correct one and changed all the files as per advised on this forum topic: http://forum.mamp.info/viewtopic.php?f=2&t=11974.
But it did not work at all. I realized that there was two phpMyAdmin folder on my Mac one which is in
/Applications/MAMP/Library/bin/phpMyAdmin
and the other one in
Library/Application Support/appsolute/MAMP PRO/phpMyAdmin
In the first folder the config.inc.php as the correct credential for the user, however the second as root for both username and password. Obviously I tried to changed that but to no avail, the file is somehow always reverted to the default credential.
Did someone ever had this issue? is there a way to solve this?

I forgot to update this, if anyone is interested I got the fix for this (and I know many people had a similar issue).
In mamp.pro.global.preferences.plist is listed the encoded MySQLRootPassword, if like me you did update of your MAMP overrite this password field with your old one and there you have it, it works !

The phpMyAdmin configuration storage is not completely configured, some extended features have been deactivated. Find out why.
Or alternately go to 'Operations' tab of any database to set it up there..

Related

root#localhost access denied for MySQL on mac system restart

I have Mac and installed MySQL in it for db connections and currently I am using laravel 8.
Everything runs smoothly until I restart or turn off my system .... The problem it causes is .. it throws me an error ...
i.e root#localhost access user denied for user
But the strange part is I haven't changed it anywhere neither I touched MySQL nor any manipulations in settings but somehow it is giving me this error....
For the solution I have searched and tried to recover my password and at last I had to delete all the db and alter my root password but it resulted in all data deletion ...Now I was working fine but again as I restarted my machine it again showed me that error.... Now my question is what actually happening here..
The problem in short is as soon as I restart my system my MySQL password starts giving an error having wrong password everytime..
So any helps or any hints what actually the problem is ...Maybe there is some mis configuration or settings issue .
Thanks in advance

MySQL root user suddenly not connecting using password

I was following a Ruby on Rails tutorial (fairly new to this language) and suddenly started having some problems connecting with MySQL on my Mac. While doing the tutorial I believe I changed the shell location using similar steps in this guide, not sure if that’s important at all.
My $PATH returns:
-bash: /Users/[MYUSERNAME]/.rbenv/shims:/usr/local/bin:/usr/local/sbin:/usr/local/mysql/bin://usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin: No such file or directory
Anyway, I’ve been working through the tutorial and have been developing since then but I went to check my files a week or so later and suddenly cannot connect to MySQL at all, if I enter mysql -u root -p (then enter correct password as it always has been) I get:
ERROR 1045 (28000): Access denied for user 'root'#'localhost' (using password: YES)
I’ve got MySQL Workbench although I rarely use it, and I use the System Preferences App to start and stop my server. I also have MAMP which I was using a while ago but I haven’t used it since using RoR.
Strange thing is, this happened before and I couldn’t connect, I was searching around for ages trying to find a solution and (not sure what I did, probably nothing substantial) it started working again. But once again it’s happened and think it’s time I learnt what the problem is so I don’t keep running into it.
Personally, I think I should’ve learnt MySQL in more depth before blind-following a tutorial assuming it’d be fine.
Any help would be greatly appreciated, thanks!
Let me know if you need me to provide anything else.
Simple answer in the end, I followed this tutorial and was able to reset the root password and it fixed everything.

MySQL security and symfony2

Working with Symfony2.3.4 and Xampp with PHP 5.6.3.
Basically my goal is to prevent anyone from tampering with the database tables directly via any manager(for example: phpmyadmin which comes with xampp via localhost/phpmyadmin/)
I'd like to find a way to set a password.
I looked for an option in phpmyadmin to set some type of security and found none.
I tried to set a password for the database via the config interface provided by the AcmeDemoBundle which i've always used to set the parameters.yml, all that did was to throw this at my face:
SQLSTATE[HY000] [1045] Access denied for user 'root'#'localhost' (using password: YES)
I need to know what I'm missing, is there a way to continue from here, or am I doing it wrong right from the beginning.
Remember: the goal is to let no one without authorization access the tables of the database in any way.
thank you
Thanks guys, I found what I needed here, answered by Anagio,
in the end what I had to do was to change the auth_type from config to http and voilá, a prompt appears when I hit localhost/phpmyadmin/ asking for user and pass.
Now all I have to do is to set a password for localhost and no one will be able to do anything to the database from outside the symfony app (hopefully)

phpmyadmin MySQL access error

I am having issues attempting to access a local phpmyadmin; and I'm sure some people may have run into this issue before.
The issue seems to be arising from previous installations and configurations.
I have IIS installed, which naturally takes up port 80. However I have successfully installed WAMP and attached it to port 8080 so as to avoid conflicts. I have installed phpmyadmin to run from both platforms, however neither is working.
Through IIS the browser throws a 403.14 - Forbidden error whilst through WAMP phpmyadmin returns the following message
MySQL said:
1045 - Access denied for user 'root'#'localhost' (using password: NO)
I believe that at least one of these errors is due to an earlier installation of Wordpress through WebMatrix (which has gone predominantly unused) which changed the MySQL (5.1) username and password defaults.
Googling the issue resulted in what seemed a promising source which claimed that one can edit a file called config.inc.php which contains the password details which are used by phpmyadmin to log into the local MySQL db. However, I couldn't find such a file (instead one named config.sample.inc.php which contained some similar information contained in the tutorial, but crucially without the relevant password field).
This isn't an absolutely critical issue as hosted dbs are ultimately necessary, but local versions nevertheless ease development.
in case you do not find config.inc.php then you can create one..
for details you may check this link..

Can't login into PhpMyAdmin EasyPHP after setting password

I installed EasyPHP 5.3.6, opened PhpMyAdmin, created a new databased and set password for root user. "Naturally" following that I was unable to login into PhpMyAdmin anymore, getting the infamous 1045 Access Denied error.
I tried everything I could find - setting password (in two places) in config.inc.php doesn't seem to work. I also tried changing AllowNoPassword to true (or false, whichever one it was not originally), that didn't do anything. I tried going through phpmyadmin/scripts/signon.php and enter the password there (it's the correct password, I saved it in my password manager) and couldn't login either. I also tried following instructions for resetting MySQL password I found but they used a mysqld-nt.exe which I didn't find in my installation. I also tried uninstalling EasyPHP and reinstalling it (and before doing that I used ccleaner to remove any registry issues it found, though admittedly there was nothing there about mysql) and it of course retained the "incorrect password" and wouldn't let me login.
Short of reformatting my harddrive I'm not sure what else I can do. (How does it keep the broken settings after uninstall??)
Any help would be appreciated.
I also would like to understand why doing something supposedly good to protect your database turns out to be such a painful procedure that it is actually recommended to leave the root user without a password? sigh
Go to EasyPHP-12.1\modules\ folder. Open folder for PhPMyAdmin version you are using (in my case it was phpmyadmin356x130206112511). Find file config.inc.php. Right click edit with Notepad.
Under line:
$cfg['Servers'][$i]['host'] = '127.0.0.1';
paste this line:
$cfg['Servers'][$i]['password'] = 'YOURPASSWORD';
where YOURPASSWORD is your desired password.
Save file and refresh the "Local Web" page.
Clearing cache allowed me to get to phpmyadmin after re-installing easyphp. Thanks to Danae above.
I just killed mysql and restarted, it worked fine for me.
Happened to me also. Unfortunately my internet decided to go down at the same time and I was unable to google this page. The "help" that comes up when you are denied access is really lame ( but hat's off to easyphp creator. ) The "help" tells you " check your configuration files"