我的编程空间,编程开发者的网络收藏夹
学习永远不晚

MySQL Error number: MY-010967; Symbol: ER_ANONYMOUS_AUTH_ID_NOT_ALLOWED_IN_MANDATORY_ROLES; SQLSTATE

短信预约 -IT技能 免费直播动态提醒
省份

北京

  • 北京
  • 上海
  • 天津
  • 重庆
  • 河北
  • 山东
  • 辽宁
  • 黑龙江
  • 吉林
  • 甘肃
  • 青海
  • 河南
  • 江苏
  • 湖北
  • 湖南
  • 江西
  • 浙江
  • 广东
  • 云南
  • 福建
  • 海南
  • 山西
  • 四川
  • 陕西
  • 贵州
  • 安徽
  • 广西
  • 内蒙
  • 西藏
  • 新疆
  • 宁夏
  • 兵团
手机号立即预约

请填写图片验证码后获取短信验证码

看不清楚,换张图片

免费获取短信验证码

MySQL Error number: MY-010967; Symbol: ER_ANONYMOUS_AUTH_ID_NOT_ALLOWED_IN_MANDATORY_ROLES; SQLSTATE

文档解释

Error number: MY-010967; Symbol: ER_ANONYMOUS_AUTH_ID_NOT_ALLOWED_IN_MANDATORY_ROLES; SQLSTATE: HY000

Message: Can’t set mandatory_role %s@%s: Anonymous authorization IDs are not allowed as roles.

错误说明

MY-010967 ER_ANONYMOUS_AUTH_ID_NOT_ALLOWED_IN_MANDATORY_ROLES错误指的是“禁止在强制性角色中使用匿名授权ID”。在MySQL服务器中,创建一个或多个强制性角色,则不能向它们授予匿名用户的权限。匿名用户的权限禁止针对强制性角色,因为MySQL不认可匿名用户的安全性。

常见案例

一个常见的场景,会触发这个错误,是当管理员试图将匿名用户授权给被设置为强制的角色时,会抛出此错误。例如,当我们试图执行以下语句时:

GRANT SELECT ON *.* TO ‘@localhost’@’%’ WITH MANDATORY ROLES;

将会抛出以下错误:

ERROR MY-010967 (HY000): Anonymous authentication ID ‘@localhost’@’%’ is not allowed in mandatory roles.

解决方法

要解决MY-010967 ER_ANONYMOUS_AUTH_ID_NOT_ALLOWED_IN_MANDATORY_ROLES错误,首先要确定问题的根源,以及正在使用的正确的授权方案。可以通过修改用户设置为有效用户,而不是匿名用户来尝试修复此错误,以正确分配角色或功能。可以使用以下两个可用的MySQL命令在MySQL服务器上修改用户:

CREATE USER ‘username’@’hostname’ IDENTIFIED BY ‘password’;

GRANT ROLE role_name TO ‘username’@’hostname’;

另一种可行的解决方案是先删除已被设置为强制性的角色,然后再重新授权它们。可以使用以下命令删除特定的角色:

DROP ROLE role_name;

最后,未能遵守MySQL的规则,而触发此错误的原因,可能是管理员忘记了禁止向强制性角色授予匿名用户的权限。在执行任何操作之前,最好先对MySQL服务器中的角色和功能进行熟悉,以免出现不必要的麻烦。

免责声明:

① 本站未注明“稿件来源”的信息均来自网络整理。其文字、图片和音视频稿件的所属权归原作者所有。本站收集整理出于非商业性的教育和科研之目的,并不意味着本站赞同其观点或证实其内容的真实性。仅作为临时的测试数据,供内部测试之用。本站并未授权任何人以任何方式主动获取本站任何信息。

② 本站未注明“稿件来源”的临时测试数据将在测试完成后最终做删除处理。有问题或投稿请发送至: 邮箱/279061341@qq.com QQ/279061341

MySQL Error number: MY-010967; Symbol: ER_ANONYMOUS_AUTH_ID_NOT_ALLOWED_IN_MANDATORY_ROLES; SQLSTATE

下载Word文档到电脑,方便收藏和打印~

下载Word文档

猜你喜欢

MySQL Error number: MY-010967; Symbol: ER_ANONYMOUS_AUTH_ID_NOT_ALLOWED_IN_MANDATORY_ROLES; SQLSTATE

文档解释Error number: MY-010967; Symbol: ER_ANONYMOUS_AUTH_ID_NOT_ALLOWED_IN_MANDATORY_ROLES; SQLSTATE: HY000Message: Cant
MySQL Error number: MY-010967; Symbol: ER_ANONYMOUS_AUTH_ID_NOT_ALLOWED_IN_MANDATORY_ROLES; SQLSTATE
2023-11-05

MySQL Error number: MY-011657; Symbol: ER_GRP_RPL_FAILED_TO_REGISTER_SERVER_STATE_OBSERVER; SQLSTATE

文档解释Error number: MY-011657; Symbol: ER_GRP_RPL_FAILED_TO_REGISTER_SERVER_STATE_OBSERVER; SQLSTATE: HY000Message:
MySQL Error number: MY-011657; Symbol: ER_GRP_RPL_FAILED_TO_REGISTER_SERVER_STATE_OBSERVER; SQLSTATE
2023-11-05

MySQL Error number: MY-011419; Symbol: ER_KEYRING_AWS_FAILED_TO_ACCESS_KEY_FROM_CONF_FILE; SQLSTATE:

文档解释Error number: MY-011419; Symbol: ER_KEYRING_AWS_FAILED_TO_ACCESS_KEY_FROM_CONF_FILE; SQLSTATE: HY000Message: Could
MySQL Error number: MY-011419; Symbol: ER_KEYRING_AWS_FAILED_TO_ACCESS_KEY_FROM_CONF_FILE; SQLSTATE:
2023-11-05

MySQL Error number: MY-010426; Symbol: ER_RPL_SLAVE_FAILED_TO_INIT_A_MASTER_INFO_STRUCTURE; SQLSTATE

文档解释Error number: MY-010426; Symbol: ER_RPL_SLAVE_FAILED_TO_INIT_A_MASTER_INFO_STRUCTURE; SQLSTATE: HY000Message:
MySQL Error number: MY-010426; Symbol: ER_RPL_SLAVE_FAILED_TO_INIT_A_MASTER_INFO_STRUCTURE; SQLSTATE
2023-11-05

MySQL Error number: MY-013209; Symbol: ER_GRP_RPL_CHANNEL_THREAD_WHEN_GROUP_ACTION_RUNNING; SQLSTATE

文档解释Error number: MY-013209; Symbol: ER_GRP_RPL_CHANNEL_THREAD_WHEN_GROUP_ACTION_RUNNING; SQLSTATE: HY000Message: Cant
MySQL Error number: MY-013209; Symbol: ER_GRP_RPL_CHANNEL_THREAD_WHEN_GROUP_ACTION_RUNNING; SQLSTATE
2023-11-04

MySQL Error number: MY-010354; Symbol: ER_AUDIT_PLUGIN_DOES_NOT_SUPPORT_AUDIT_AUTH_EVENTS; SQLSTATE:

文档解释Error number: MY-010354; Symbol: ER_AUDIT_PLUGIN_DOES_NOT_SUPPORT_AUDIT_AUTH_EVENTS; SQLSTATE: HY000Message: Plugin
MySQL Error number: MY-010354; Symbol: ER_AUDIT_PLUGIN_DOES_NOT_SUPPORT_AUDIT_AUTH_EVENTS; SQLSTATE:
2023-11-05

MySQL Error number: MY-011083; Symbol: ER_DD_UPGRADE_FAILED_TO_UPDATE_VER_NO_IN_TABLESPACE; SQLSTATE

文档解释Error number: MY-011083; Symbol: ER_DD_UPGRADE_FAILED_TO_UPDATE_VER_NO_IN_TABLESPACE; SQLSTATE: HY000Message: Error
MySQL Error number: MY-011083; Symbol: ER_DD_UPGRADE_FAILED_TO_UPDATE_VER_NO_IN_TABLESPACE; SQLSTATE
2023-11-05

MySQL Error number: MY-011801; Symbol: ER_LDAP_AUTH_POOL_GET_FAILED_TO_CREATE_CONNECTION; SQLSTATE:

文档解释Error number: MY-011801; Symbol: ER_LDAP_AUTH_POOL_GET_FAILED_TO_CREATE_CONNECTION; SQLSTATE: HY000Message:
MySQL Error number: MY-011801; Symbol: ER_LDAP_AUTH_POOL_GET_FAILED_TO_CREATE_CONNECTION; SQLSTATE:
2023-11-05

MySQL Error number: MY-010993; Symbol: ER_RES_GRP_SOLARIS_PROCESSOR_BIND_TO_THREAD_FAILED; SQLSTATE:

文档解释Error number: MY-010993; Symbol: ER_RES_GRP_SOLARIS_PROCESSOR_BIND_TO_THREAD_FAILED; SQLSTATE: HY000Message:
MySQL Error number: MY-010993; Symbol: ER_RES_GRP_SOLARIS_PROCESSOR_BIND_TO_THREAD_FAILED; SQLSTATE:
2023-11-05

MySQL Error number: MY-013760; Symbol: ER_GRP_RPL_DONOR_VIEW_CHANGE_UUID_TRANS_INFO_ERROR; SQLSTATE:

文档解释Error number: MY-013760; Symbol: ER_GRP_RPL_DONOR_VIEW_CHANGE_UUID_TRANS_INFO_ERROR; SQLSTATE: HY000Message: Unable
MySQL Error number: MY-013760; Symbol: ER_GRP_RPL_DONOR_VIEW_CHANGE_UUID_TRANS_INFO_ERROR; SQLSTATE:
2023-11-05

MySQL Error number: MY-011618; Symbol: ER_GRP_RPL_REINIT_OF_COMMIT_CACHE_FOR_WRITE_FAILED; SQLSTATE:

文档解释Error number: MY-011618; Symbol: ER_GRP_RPL_REINIT_OF_COMMIT_CACHE_FOR_WRITE_FAILED; SQLSTATE: HY000Message: Failed
MySQL Error number: MY-011618; Symbol: ER_GRP_RPL_REINIT_OF_COMMIT_CACHE_FOR_WRITE_FAILED; SQLSTATE:
2023-11-05

MySQL Error number: MY-013325; Symbol: ER_CANNOT_SET_SERVER_VERSION_IN_TABLESPACE_HEADER; SQLSTATE:

文档解释Error number: MY-013325; Symbol: ER_CANNOT_SET_SERVER_VERSION_IN_TABLESPACE_HEADER; SQLSTATE: HY000Message: Cannot
MySQL Error number: MY-013325; Symbol: ER_CANNOT_SET_SERVER_VERSION_IN_TABLESPACE_HEADER; SQLSTATE:
2023-11-05

MySQL Error number: MY-010392; Symbol: ER_NDB_SLAVE_SAW_EPOCH_LOWER_THAN_PREVIOUS_ON_START; SQLSTATE

文档解释Error number: MY-010392; Symbol: ER_NDB_SLAVE_SAW_EPOCH_LOWER_THAN_PREVIOUS_ON_START; SQLSTATE: HY000Message: NDB
MySQL Error number: MY-010392; Symbol: ER_NDB_SLAVE_SAW_EPOCH_LOWER_THAN_PREVIOUS_ON_START; SQLSTATE
2023-11-05

MySQL Error number: MY-010448; Symbol: ER_EVENT_EXECUTION_FAILED_USER_LOST_EVEN_PRIVILEGE; SQLSTATE:

文档解释Error number: MY-010448; Symbol: ER_EVENT_EXECUTION_FAILED_USER_LOST_EVEN_PRIVILEGE; SQLSTATE: HY000Message: Event
MySQL Error number: MY-010448; Symbol: ER_EVENT_EXECUTION_FAILED_USER_LOST_EVEN_PRIVILEGE; SQLSTATE:
2023-11-05

MySQL Error number: MY-011223; Symbol: ER_AUDIT_LOG_FILTER_FAILED_TO_INIT_TABLE_FOR_READ; SQLSTATE:

文档解释Error number: MY-011223; Symbol: ER_AUDIT_LOG_FILTER_FAILED_TO_INIT_TABLE_FOR_READ; SQLSTATE: HY000Message: Could
MySQL Error number: MY-011223; Symbol: ER_AUDIT_LOG_FILTER_FAILED_TO_INIT_TABLE_FOR_READ; SQLSTATE:
2023-11-05

MySQL Error number: MY-011659; Symbol: ER_GRP_RPL_FAILED_TO_REGISTER_BINLOG_STATE_OBSERVER; SQLSTATE

文档解释Error number: MY-011659; Symbol: ER_GRP_RPL_FAILED_TO_REGISTER_BINLOG_STATE_OBSERVER; SQLSTATE: HY000Message:
MySQL Error number: MY-011659; Symbol: ER_GRP_RPL_FAILED_TO_REGISTER_BINLOG_STATE_OBSERVER; SQLSTATE
2023-11-05

MySQL Error number: MY-010999; Symbol: ER_DD_UPGRADE_FAILED_TO_RESOLVE_TABLESPACE_ENGINE; SQLSTATE:

文档解释Error number: MY-010999; Symbol: ER_DD_UPGRADE_FAILED_TO_RESOLVE_TABLESPACE_ENGINE; SQLSTATE: HY000Message: Error
MySQL Error number: MY-010999; Symbol: ER_DD_UPGRADE_FAILED_TO_RESOLVE_TABLESPACE_ENGINE; SQLSTATE:
2023-11-05

MySQL Error number: MY-013301; Symbol: ER_SHA256_PASSWORD_SECOND_PASSWORD_USED_INFORMATION; SQLSTATE

文档解释Error number: MY-013301; Symbol: ER_SHA256_PASSWORD_SECOND_PASSWORD_USED_INFORMATION; SQLSTATE: HY000Message:
MySQL Error number: MY-013301; Symbol: ER_SHA256_PASSWORD_SECOND_PASSWORD_USED_INFORMATION; SQLSTATE
2023-11-05

MySQL Error number: MY-010427; Symbol: ER_RPL_SLAVE_FAILED_TO_INIT_MASTER_INFO_STRUCTURE; SQLSTATE:

文档解释Error number: MY-010427; Symbol: ER_RPL_SLAVE_FAILED_TO_INIT_MASTER_INFO_STRUCTURE; SQLSTATE: HY000Message: Failed
MySQL Error number: MY-010427; Symbol: ER_RPL_SLAVE_FAILED_TO_INIT_MASTER_INFO_STRUCTURE; SQLSTATE:
2023-11-05

MySQL Error number: MY-010940; Symbol: ER_PERFSCHEMA_COMPONENTS_INFRASTRUCTURE_BOOTSTRAP; SQLSTATE:

文档解释Error number: MY-010940; Symbol: ER_PERFSCHEMA_COMPONENTS_INFRASTRUCTURE_BOOTSTRAP; SQLSTATE: HY000Message: Failed
MySQL Error number: MY-010940; Symbol: ER_PERFSCHEMA_COMPONENTS_INFRASTRUCTURE_BOOTSTRAP; SQLSTATE:
2023-11-05

编程热搜

目录