終端登錄MySQL:
mysql -uroot -p
創(chuàng)建遠程用戶并賦予操作某個數(shù)據(jù)庫的權(quán)限:
grant all privileges on newdb.* to 'newuser'@'%' identified by 'newpassword' with grant option;
myslq> flush privileges;
創(chuàng)建新的MySQL用戶:
create user test identified by '123456';
查看所有MySQL用戶:
select host, user from mysql.user;
如仍然無法遠程連接牲平,打開mysql文件凤薛,注釋掉如下部分:
bind-address = 127.0.0.1