A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from http://cloud.google.com/compute/docs/disks/set-snapshot-scope below:

Set creation and restore locations for regionally scoped snapshots | Compute Engine Documentation

Set creation and restore locations for regionally scoped snapshots

Stay organized with collections Save and categorize content based on your preferences.

Preview

This product or feature is subject to the "Pre-GA Offerings Terms" in the General Service Terms section of the Service Specific Terms. Pre-GA products and features are available "as is" and might have limited support. For more information, see the launch stage descriptions.

By default, snapshots are created with a global scope. Globally scoped snapshots are stored in a specific storage location and can be restored (used to create a new disk) in any region or zone. For additional location-based isolation control, you can create regionally scoped snapshots. Regionally scoped snapshots store all snapshot data and metadata together in the scoped region. With regionally scoped snapshots, you can also restrict the regions where you can create and restore snapshots.

This document explains how to set allowed locations for regional snapshot creation and restoration.

Before you begin Limitations Required roles and permissions

To get the permissions that you need to set storage and restore locations for regionally scoped snapshots, ask your administrator to grant you the following IAM roles on the project:

For more information about granting roles, see Manage access to projects, folders, and organizations.

These predefined roles contain the permissions required to set snapshot creation and restore locations. To see the exact permissions that are required, expand the Required permissions section:

Permissions required for this task

To perform this task, you must have the following permissions:

Set allowed snapshot creation locations

By default, you can create snapshots in all regions. To restrict where you can create regionally scoped snapshots, set allowed access locations at the project level. Once you set access locations, you can create regionally scoped snapshots for the project only in these locations.

gcloud

To let zonal disks in Zone A create snapshots in any region, use the gcloud beta compute disk-settings update command:

  gcloud beta compute disk-settings update \
      --zone=ZONE_A \
      --access-location-policy=all-regions \

To let regional disks in Region A create snapshots in any region, use the gcloud beta compute disk-settings update command:

  gcloud beta compute disk-settings update \
      --region=REGION_A \
      --access-location-policy=all-regions

To let disks in Region A create snapshots only in Region B, use the gcloud beta compute disk-settings update command:

  gcloud beta compute disk-settings update \
      --access-location-policy=specific-regions \
      --region=REGION_A \
      --add-access-locations=REGION_B

Replace the following:

REST

To let zonal disks in Zone A create snapshots in any region, make a PATCH request to the diskSettings.patch method:

  PATCH https://compute.googleapis.com/compute/beta/projects/PROJECT_ID/zones/ZONE_A/diskSettings?updateMask=accessLocation

  {
    "accessLocation":
    {
      "policy":"ALL_REGIONS"
    }
  }

To let regional disks in Region A create snapshots only in Region B, make a PATCH request to the regionDiskSettings.patch method:

  PATCH https://compute.googleapis.com/compute/beta/projects/PROJECT_ID/regions/REGION_A/diskSettings?updateMask=accessLocation

  {
    "accessLocation":
    {
      "policy":"SPECIFIC_REGIONS",
      "locations":
      {
        "REGION_B":{"region":"REGION_B"}
      }
    }
  }

Replace the following:

Set allowed snapshot restore locations

By default, you can restore regionally and globally scoped snapshots to any region. To configure restore locations for your regionally scoped snapshots, set allowed access locations at the project level. You must set allowed access locations for each project individually. Once you set access locations, you can restore regionally scoped snapshots for the project only in these locations.

gcloud

To let snapshots for a project in Region A be restored in all regions, use the gcloud beta compute snapshot-settings update command:

  gcloud beta compute snapshot-settings update \
      --project=PROJECT_ID \
      --region=REGION_A \
      --access-location-policy=all-regions

To let snapshots for a project in Region A be restored only in Region B, use the gcloud beta compute snapshot-settings update command:

  gcloud beta compute snapshot-settings update \
      --project=PROJECT_ID \
      --access-location-policy=specific-regions \
      --region=REGION_A \
      --add-access-locations=REGION_B

Replace the following:

REST

To let snapshots for a project in Region A be restored in all regions, make a PATCH request to the regionSnapshotSettings.patch method:

  PATCH https://compute.googleapis.com/compute/v1/projects/PROJECT_ID/regions/REGION_A/snapshotSettings?updateMask=accessLocation

  {
    "accessLocation":
    {
      "policy":"ALL_REGIONS"
    }
  }

To let snapshots for a project in Region A be restored only in Region B, make a PATCH request to the regionSnapshotSettings.patch method:

  PATCH https://compute.googleapis.com/compute/v1/projects/PROJECT_ID/regions/REGION_A/snapshotSettings?updateMask=accessLocation

  {
    "accessLocation":
    {
      "policy":"SPECIFIC_REGIONS",
      "locations":
        {"REGION_B":
          {"region":"REGION_B"}
        }
    }
  }

Replace the following:

Edit allowed snapshot restore locations gcloud

To view the allowed restore locations for snapshots for a project stored in Region A, use the gcloud beta compute snapshot-settings describe command:

  gcloud beta compute snapshot-settings describe \
      --project=PROJECT_ID \
      --region=REGION_A

To remove Region B from the list of allowed restore locations for snapshots for a project stored in Region A, use the gcloud beta compute snapshot-settings update command:

  gcloud beta compute snapshot-settings update \
      --project=PROJECT_ID \
      --access-location-policy=specific-regions \
      --remove-access-locations=REGION_B \
      --region=REGION_A

Replace the following:

REST

To view the allowed restore locations for snapshots for a project stored in Region A, make a GET request to the regionSnapshotSettings.get method:

  GET https://compute.googleapis.com/compute/v1/projects/PROJECT_ID/regions/REGION_A/snapshotSettings

To remove Region B from the list of allowed restore locations for snapshots for a project stored in Region A, make a PATCH request to the regionSnapshotSettings.patch method:

  PATCH https://compute.googleapis.com/compute/v1/projects/PROJECT_ID/regions/REGION_A/snapshotSettings?updateMask=accessLocation

  {
    "accessLocation":
    {
      "policy":"SPECIFIC_REGIONS",
      "locations":
        {"REGION_B":{}}
    }
  }

Replace the following:

Except as otherwise noted, the content of this page is licensed under the Creative Commons Attribution 4.0 License, and code samples are licensed under the Apache 2.0 License. For details, see the Google Developers Site Policies. Java is a registered trademark of Oracle and/or its affiliates.

Last updated 2025-08-07 UTC.

[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Hard to understand","hardToUnderstand","thumb-down"],["Incorrect information or sample code","incorrectInformationOrSampleCode","thumb-down"],["Missing the information/samples I need","missingTheInformationSamplesINeed","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2025-08-07 UTC."],[],[]]


RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4