Manage access to AI zones

This page explains how to check if AI zones are enabled for your Google Cloud project, and how to enable them or turn them off. AI zones are specialized zones used for Artificial Intelligence and Machine Learning (AI and ML) training and inference workloads. To use AI zones, you must turn them on for your Google Cloud project. This turns on AI zones for all Google Cloud services.

This page explains how to check if AI zones are enabled for your Google Cloud project, and how to enable them or turn them off.

To learn more about AI zones, read the AI zones documentation.

Before you begin

  • If you haven't already, set up authentication . Authentication verifies your identity for access to Google Cloud services and APIs. To run code or samples from a local development environment, you can authenticate to Compute Engine by selecting one of the following options:

    Select the tab for how you plan to use the samples on this page:

    Console

    When you use the Google Cloud console to access Google Cloud services and APIs, you don't need to set up authentication.

    gcloud

    1. Install the Google Cloud CLI. After installation, initialize the Google Cloud CLI by running the following command:

      gcloud  
      init

      If you're using an external identity provider (IdP), you must first sign in to the gcloud CLI with your federated identity .

    2. Set a default region and zone .

    REST

    To use the REST API samples on this page in a local development environment, you use the credentials you provide to the gcloud CLI.

      Install the Google Cloud CLI.

      If you're using an external identity provider (IdP), you must first sign in to the gcloud CLI with your federated identity .

    For more information, see Authenticate for using REST in the Google Cloud authentication documentation.

Required roles

To get the permissions that you need to turn on or turn off AI zones, ask your administrator to grant you the Compute Admin ( roles/compute.admin ) IAM role on the project. For more information about granting roles, see Manage access to projects, folders, and organizations .

You might also be able to get the required permissions through custom roles or other predefined roles .

Check if AI zones are turned on for a project

To check if AI zones are turned on for your Google Cloud project, verify whether or not the feature ai-zones-visibility ( Preview ) is turned on for your Google Cloud project. For new Google Cloud projects, AI zones are turned off by default.

Google Cloud CLI

Use the gcloud compute preview-features list command . The response that you get indicates if the feature ai-zones-visibility is turned on or turned off.

gcloud compute preview-features list ai-zones-visibility

REST

Make the following GET request to the previewFeatures.list method .

GET https://compute.googleapis.com/compute/v1/projects/ PROJECT_ID 
/global/previewFeatures/ai-zones-visibility

Replace PROJECT_ID with your project ID .

Turn on AI zones

To get access to AI zones, turn them on for your Google Cloud project.

Google Cloud CLI

Use the gcloud compute preview-features command , setting the activation status as enabled and the rollout plan as fast-rollout .

gcloud compute preview-features update ai-zones-visibility \
    --activation-status=enabled \
    --rollout-plan=fast-rollout

REST

Make the following PATCH request to the previewFeatures.update method . In the request body, include the following fields:

  • The activation_status field, set to ENABLED .
  • The rollout_operation.predefined_rollout_plan field, set to ROLLOUT_PLAN_FAST_ROLLOUT .
PATCH https://compute.googleapis.com/compute/v1/projects/ PROJECT_ID 
/global/previewFeatures/ai-zones-visibility
{
  "activation_status": "ENABLED",
  "rollout_operation": {
    "rollout_input": {
      "predefined_rollout_plan": "ROLLOUT_PLAN_FAST_ROLLOUT"
    }
  }
}

Replace PROJECT_ID with your project ID .

Turn off AI zones

To remove access to AI zones, turn them off for your Google Cloud project. When you turn off AI zones, you lose access to any resources that you've deployed in AI zones.

Google Cloud CLI

Use the gcloud compute preview-features command , setting the activation status as unspecified and the rollout plan as fast-rollout .

gcloud compute preview-features update ai-zones-visibility \
    --activation-status=unspecified \
    --rollout-plan=fast-rollout

REST

Make the following PATCH request to the previewFeatures.update method . In the request body, include the following fields:

  • The activation_status field, set to ACTIVATION_STATE_UNSPECIFIED .
  • The rollout_operation.predefined_rollout_plan field, set to ROLLOUT_PLAN_FAST_ROLLOUT .
PATCH https://compute.googleapis.com/compute/v1/projects/ PROJECT_ID 
/global/previewFeatures/ai-zones-visibility
{
  "activation_status": "ACTIVATION_STATE_UNSPECIFIED",
  "rollout_operation": {
    "rollout_input": {
      "predefined_rollout_plan": "ROLLOUT_PLAN_FAST_ROLLOUT"
    }
  }
}

Replace PROJECT_ID with your project ID .

What's next

Create a Mobile Website
View Site in Mobile | Classic
Share by: