配置mac版mysql:
2017-07-10 本文已影响9人
d76d0c9d2b04
配置mac版mysql:
1.打开终端,cd ~
2.输入命令: open .bash_profile
3.修改打开的文本文件输入:export PATH=${PATH}:/usr/local/mysql-5.7.11-osx10.9-x86_64/bin
4.登录:mysql -uroot -p
5.修改密码:mysql> SET PASSWORD FOR 'root'@'localhost' = PASSWORD('MyNewPass');
6.更新密码:UPDATE mysql.user SET authentication_string = PASSWORD('MyNewPass')
WHERE User = 'root' AND Host = 'localhost';
FLUSH PRIVILEGES;