GKE Autopilot执行kubectl命令偶现Forbidden错误求助
GKE Autopilot偶现"request was sent before policy enforcement is enabled"权限错误
环境
- GKE Autopilot v1.22.12-gke.2300
- 操作环境:Ubuntu 20.04虚拟机,通过
kubectl执行命令 - 认证方式:使用
gke-gcloud-auth-plugin插件
问题详情
执行kubectl get pod等命令时,约40%概率会触发Forbidden错误,错误信息如下:
Error from server (Forbidden): pods is forbidden: User "my-mail@domain.com" cannot list resource "pods" in API group "" in the namespace "default": GKEAutopilot authz: the request was sent before policy enforcement is enabled
已排除IAM权限问题(错误非必现),此前使用GKE Autopilot v1.21.x版本时该问题出现频率极低,搜索相关关键词未找到有效解决方案,求有相同经历的朋友提供排查思路。
内容的提问来源于stack exchange,提问作者Ryo
相关产品推荐
相关产品推荐

