![]() I want to preface this with for some reason I do not understand these changes to not propagate quickly, and suddenly just start working. You will need to fix your phpmyadmin as well. ![]() Login to mysql to confirm that things work. Shut down mysqld and restart it without the skip-grant-tables option GRANT ALL ON *.* TO IDENTIFIED BY 'password' In your console login to mysql with no creds. Applications/MAMP/Library/libexec/mysqld -skip-grant-tables -port=8889 -socket=/Applications/MAMP/tmp/mysql/mysql.sock This will start mysql minus the user permissions. Run the following command, replacing the port number with the one you use. Now, you might see a _mysqld process running which might be the default OSX mysql running. Ensure that mysql is shut off in Activity Monitor.In the end here is what I did, and I want to make clear this is the instructions for a MAMP installation on OS X, although I'm sure they can be easily adapted for Windoz.īig thanks to this thread for helping me see the light on how to resolve this. ![]() I believe I exacerbated this situation a bit by running some commands like the below. So something about my root account changed (I believe it was the password), but how the whole thing responded was a bit wonky, as in instead of telling me my password and username combo was incorrect, I was getting logged in with no permissions. I still don't understand a few of the details but here we go.Įven though I was logging in as root the reality was that I was an anonymous user indicated by the above and So there is obviously a permissions error which has three parts: username, password, and host. It took a while to put the pieces together because the MAMP installation is a bit different then a standard mysql installation. I find this very confusing?Īfter several days of beating my head on this I discovered the solution. So when I connect as localhost either by IP or socket I am somehow not logged in as root. Mysql> SHOW GRANTS FOR 1044 (42000): Access denied for user to database 'mysql' | GRANT ALL PRIVILEGES ON `db`.* TO WITH GRANT OPTION |īut when I connect as: /Applications/MAMP/Library/bin/mysql -uroot -hlocalhost -p | GRANT ALL PRIVILEGES ON *.* TO WITH GRANT OPTION | When I connect as: /Applications/MAMP/Library/bin/mysql -uroot -h127.0.0.1 -p Lesson learned here is don't be lazy and screw around with your root user locally and just create another login. I either have to fix the original install or make it so the all tables show for my dbs in my fresh mamp install. While it works, I've run into instances where DBs are not showing all the tables. I've installed a fresh installation of MAMP and copied over my DBs. show grants for ALL PRIVILEGES ON *.* TO WITH GRANT OPTION Connecting as root in the shell I don't have permission as localhost but I do as 127.0.0.1. ![]() skip-grant-tables does not seem to work. I tried many things to restore the privileges that I read here and elsewhere to no avail. After rebooting my machine phpmyadmin in mamp no longer displayed any of my dbs and showed "No Privileges" to create a database. I made a change to my root user the other day in an attempt to get a local service to connect properly. I've read many threads on SO and a few other places and haven't been able to fix my mysql installation in MAMP.īackground.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |