mysql -p --输入密码 use mysql
授权
grant all on dbname.* to username&'%' identified by '123456'; flush privileges;
取消授权
revoke all on dbname.* from username@'%'; flush privileges;