MySQL8.0报错:Access denied; you need (at least one of) the SYSTEM_USER privilege(s) for this operation

MySQL8.0.16版本中新增了一个system_user帐户类型,当新增用户并赋予权限时

mysql> create user 'proxysql'@'192.168.20.%' identified  with mysql_native_password by 'iD!^^EjU#Yxr5$p';
ERROR 1227 (42000): Access denied; you need (at least one of) the SYSTEM_USER privilege(s) for this operation

# 原因是由于root用户没有SYSTEM_USER权限,把权限加入后即可解决

mysql> grant system_user on *.* to 'root';
Query OK, 0 rows affected (0.00 sec)
posted @ 2022-05-25 10:31  哈喽哈喽111111  阅读(2735)  评论(0编辑  收藏  举报