If you have recently transferred your site to your current machine, it is possible that your setup is using a. Make sure this is the same as the your username and password you are currently using. If you are using a CMS, you set up access to the database when you set up your site. By default, MAMP uses user root, with a password of root.In the terminal, type in: mysql -u root -p. Now try again to access MySQL with root. There is no need to restart the mysqld service to log in. After you run the commands listed above, exit the MySQL shell by pressing CTRL + D on your keyboard or type exit and hit enter.
Mysql Access Denied For User 'Norman'@'Localhost' (Using : No) Password You AreI found one simple way to fix this on macOS or OSX. Some of them worked for me some of them not. Execute the following command (*scroll right if you don't the full query): UPDATE mysql.user SET authentication_string='your-password-goes-here' WHERE user='root' and host='localhost' (in my case) is the installation folder on your local machine, and it might or might not be different than mine because of OS versions, mysql versions, installation methods used, etc.Very Simple Fix for MariaDB version: 10.4.6-MariaD on Mojave macOSI have gone through all the answers. Execute the following command:$mysql> UPDATE user SET authentication_string=PASSWORD("my_password") WHERE User='root' A) The command for MySql versions before 5.7 was:$mysql> UPDATE user SET Password=PASSWORD('my_password') where USER='root' B) If you see ERROR 1046 (3D000): No database selected, then run this command first:C) If you see unknown "Password" field error, then run this command:UPDATE USER SET AUTHENTICATION_STRING=password('NewPassword') WHERE user='root' Restart MySQL, either through System Preferences > MySql or using a command.BUT THIS ACTUALLY WORKED: sudo /usr/local/mysql-8.0.15-macos10.14-x86_64/support-files/mysql.server stopThe installation folder might vary per user, BE AWARE!Or just Check > System preferences > MySQL > if the server is running, stop it.Start MySQL with this command: sudo /usr/local/mysql-8.0.15-macos10.14-x86_64/bin/mysqld_safe -skip-grant-tablesOpen a new terminal window/tab: sudo /usr/local/mysql-8.0.15-macos10.14-x86_64/bin/mysql -u rootThis should open "mysql" prompt. Windows migration assistant for mac os sierra downloadGet into MySQL instance sudo mysql -u rootNOTE: mysql -u root will throw error ERROR 1698 (28000): Access denied for user so use sudo to run this command.Now to change the password of the root user I tried the following commands: Start MySQL Server: mysql.server start or run brew services start mariadbTo start MySQL Server at login to the computer. Use the following link to install homebrew on macOS or OSX.
0 Comments
Leave a Reply. |
AuthorJohn ArchivesCategories |