It is indeed the same command from the output of pgrep -fl mysql but in this case, you just need to add: -skip-grant-tables -skip-networkingĪfter doing that you will notice that the menu from the System Preferences is Green again and MySQL should be up and running, now you can try to login and change password: mysql -uroot user=_mysql -basedir=/usr/local/mysql -datadir=/usr/local/mysql/data -plugin-dir=/usr/local/mysql/lib/plugin -log-error=/usr/local/mysql/data/ -pid-file=/usr/local/mysql/data/ ![]() Next step is to stop MySQL, you can do this by clicking on the System Preferences menu and click on the Stop MySQL Server button, Once is stoped within a terminal you will need to start again the server but with some extra options, something like this: sudo /usr/local/mysql/bin/mysqld \ That will help you to find the path of mysqld and the current command used to start the server, the output could be something like this: 6283 /usr/local/mysql/bin/mysqld -user=_mysql -basedir=/usr/local/mysql -datadir=/usr/local/mysql/data -plugin-dir=/usr/local/mysql/lib/plugin -log-error=/usr/local/mysql/data/ -pid-file=/usr/local/mysql/data/ If is up and running open a terminal and run this command: pgrep -fl mysql This is how you can do it in macOS Sierra, probably you install it via pkg and in the system preferences have an icon for MySQL, something like this: _mysql 124 0.0 0.0 2864848 4040 ? Ss 22Sep17 0:32.26 /usr/local/mysql/bin/mysqld -user=_mysql -basedir=/usr/local/mysql -datadir=/usr/local/mysql/data -plugin-dir=/usr/local/mysql/lib/plugin -log-error=/usr/local/mysql/data/ -pid-file=/usr/local/mysql/data/ -keyring-file-data=/usr/local/mysql/keyring/keyring -early-plugin-load=keyring_file=keyring_file.soīheng 95863 0.0 0.0 2423384 396 s009 R 8:48AM 0:00.00 grep mysqlīheng 95749 0.0 0.0 2448756 2496 ? S 8:48AM 0:00.03 /bin/sh /usr/local/opt/mysql/bin/mysqld_safe -bind-address=127.0.0.1 -datadir=/usr/local/var/mysqlīheng 66379 0.0 0.1 2696936 9304 ? S 8:06AM 0:00.51 /Applications/MAMP/Library/bin/mysqld -basedir=/Applications/MAMP/Library -datadir=/Applications/MAMP/db/mysql -plugin-dir=/Applications/MAMP/Library/lib/plugin -log-error=/Applications/MAMP/logs/mysql_error_log.err -pid-file=/Applications/MAMP/tmp/mysql/mysql.pid -socket=/Applications/MAMP/tmpmysql/mysql.sock -port=8889īheng 66263 0.0 0.0 2446708 2100 ? S 8:06AM 0:00.02 /bin/sh /Applications/MAMP/Library/bin/mysqld_safe -port=8889 -socket=/Applications/MAMP/tmp/mysql/mysql.sock -pid-file=/Applications/MAMP/tmp/mysql/mysql.pid -log-error=/Applications/MAMP/logs/mysql_error_log I can't really set the root password because I can't even get in. ![]() T12:13:44.6NZ mysqld_safe mysqld from pid file /usr/local/var/mysql/ ended ![]() T12:13:42.6NZ mysqld_safe Starting mysqld daemon with databases from /usr/local/var/mysql I need help.Įnter password: <- I've tried almost 10 possible passwordsĮRROR 1045 (28000): Access denied for user (using password: NO)ĮRROR! MySQL server PID file could not be found! I start my MAMP and try to connect to my MySQL server via localhost or 127.0.0.1, I tried all the possible password that I think it is correct, but for some reasons it still didn't like it, so I think I forgot it somehow.
0 Comments
Leave a Reply. |