mysql远程访问

1、mysql -u root -p

 

2、grant all privileges on *.* to 'root'@'%' identified by '123456' with grant option;

 

flush privileges;

 

3、打开/usr/local/Cellar/mysql/5.7.16/下的homebrew.mxcl.mysql.plist文件,去掉

 

--bind-address=127.0.0.1

或0.0.0.0

 

4、brew services stop mysql

 

brew services start mysql

posted @ 2017-07-12 10:08  zgj12306  阅读(133)  评论(0)    收藏  举报