mysql> grant all privileges on *.* to 'root'@'%' identified by '123456' with grant option; flush privileges;設置了以后怎么取消原來的設置?
2 回答
已采納

luofuxiang
TA貢獻34條經(jīng)驗 獲得超34個贊
樓主在本地用root用戶登陸,此時登陸的用戶為root@'locallhost',然后刪除root@'%'用戶,這樣就只能自己訪問自己的服務器了,別人無法從其它的主機登陸MySql,具體代碼如下:
drop?user?root@'%';????/*刪除用戶*/ ?flush?privileges;????/*更新權限緩存*/
添加回答
舉報
0/150
提交
取消