在設備管理控制台中備份、掛接及還原 Compute Engine 執行個體所需的 IAM 角色和權限

本頁列出備份、掛接及還原 Compute Engine 執行個體所需的角色和權限。

必要的角色

如要備份、掛接及還原執行個體,建議您將下列 IAM 角色授予備份/復原設備使用的服務帳戶。

如要取得備份、掛接及還原 Compute Engine 執行個體所需的權限,請要求管理員授予您專案的備份和災難復原 Compute Engine 操作者 (roles/backupdr.computeEngineOperator) IAM 角色。如要進一步瞭解如何授予角色,請參閱「管理專案、資料夾和組織的存取權」。

您或許也能透過自訂角色或其他預先定義的角色,取得必要權限。

如要使用自訂角色,請務必加入下節列出的所有權限。

精細權限

下表比較不同 Compute Engine 作業所需的細部權限。

權限 備份 支架 (現有) 還原 / 掛接 (新)
Compute Engine
compute.addresses.list
compute.disks.create
compute.disks.createSnapshot
compute.disks.delete
compute.disks.get
compute.disks.setLabels
compute.disks.use
compute.diskTypes.get
compute.diskTypes.list
compute.firewalls.list
compute.globalOperations.get
compute.images.create
compute.images.delete
compute.images.get
compute.images.useReadOnly
compute.instances.attachDisk
compute.instances.create
compute.instances.delete
compute.instances.detachDisk
compute.instances.get
compute.instances.list
compute.instances.setLabels
compute.instances.setMetadata
compute.instances.setServiceAccount
compute.instances.setTags
compute.instances.start
compute.instances.stop
compute.machineTypes.get
compute.machineTypes.list
compute.networks.list
compute.nodeGroups.get
compute.nodeGroups.list
compute.nodeTemplates.get
compute.projects.get
compute.regions.get
compute.regions.list
compute.regionOperations.get
compute.snapshots.create
compute.snapshots.delete
compute.snapshots.get
compute.snapshots.setLabels
compute.snapshots.useReadOnly
compute.subnetworks.list
compute.subnetworks.use
compute.subnetworks.useExternalIp
compute.zoneOperations.get
compute.zones.list
IAM
iam.serviceAccounts.actAs
iam.serviceAccounts.get
iam.serviceAccounts.list
Resource Manager
resourcemanager.projects.get
resourcemanager.projects.list

CMEK 權限

如果來源磁碟使用客戶自行管理的加密金鑰 (CMEK),Compute Engine 服務代理需要來源專案中金鑰的 roles/cloudkms.cryptoKeyEncrypterDecrypter 角色。

如要授予這項權限,請按照下列步驟操作:

  1. 前往 Google Cloud 控制台的「IAM」頁面,然後選取目標專案。 前往「IAM」頁面
  2. 選取「包含 Google 提供的角色授予項目」
  3. 找出「Compute Engine Service Agent」服務帳戶,並複製其電子郵件地址 (主體)。
  4. 切換至 KMS 金鑰所在的來源專案
  5. 按一下「授予存取權」,然後貼上服務帳戶電子郵件地址。
  6. 選取「Cloud KMS CryptoKey Encrypter/Decrypter」(Cloud KMS CryptoKey 加密者/解密者) 角色,然後按一下「Save」(儲存)

相關資訊