首页 > 解决方案 > 无法在 AI Platform 中启动/停止 AI Platform Notebook 实例,但能够在 Compute Engine 中启动/停止

问题描述

我正在为用户设置使用 GCP AI Platform 中预先创建的 AI Platform VM 实例的权限。我创建了一个具有权限的自定义角色

compute.acceleratorTypes.list
compute.diskTypes.list
compute.instances.list
compute.instances.start
compute.instances.stop
compute.machineTypes.list
compute.subnetworks.list
iam.serviceAccounts.actAs
notebooks.environments.get
notebooks.environments.getIamPolicy
notebooks.environments.list
notebooks.instances.get
notebooks.instances.getIamPolicy
notebooks.instances.list
notebooks.locations.get
notebooks.locations.list
notebooks.operations.get
notebooks.operations.list
resourcemanager.projects.get

用户可以从 GCP 控制台的 Compute Engine 部分启动和停止实例,但不能从 AI Platform 部分启动和停止实例。当我尝试后者时,我得到了错误:

sample-ai-platform-vm: Permission 'notebooks.instances.start' denied on 'projects/test-project/locations/us-east1-b/instances/sample-ai-platform-vm'

知道发生了什么吗?

标签: google-cloud-platformgoogle-cloud-iamgcp-ai-platform-notebook

解决方案


您需要添加以下权限:

notebooks.instances.start
notebooks.instances.stop

您可以查看 Notebooks Admin 角色以供参考:

https://cloud.google.com/ai-platform/notebooks/docs/iam


推荐阅读