Create a runtime

This page shows you how to create, start, and delete a runtime in Colab Enterprise.

You can create a runtime to run code on a runtime that has a different configuration than the default. Runtimes are created based on a runtime template, which includes specifications like machine type and disk size.

To learn more about runtimes, see Runtimes and runtime templates.

Before you begin

  1. Sign in to your Google Cloud account. If you're new to Google Cloud, create an account to evaluate how our products perform in real-world scenarios. New customers also get $300 in free credits to run, test, and deploy workloads.
  2. In the Google Cloud console, on the project selector page, select or create a Google Cloud project.

    Go to project selector

  3. Make sure that billing is enabled for your Google Cloud project.

  4. Enable the Vertex AI, Dataform, and Compute Engine APIs.

    Enable the APIs

  5. In the Google Cloud console, on the project selector page, select or create a Google Cloud project.

    Go to project selector

  6. Make sure that billing is enabled for your Google Cloud project.

  7. Enable the Vertex AI, Dataform, and Compute Engine APIs.

    Enable the APIs

Required roles

To ensure that your user account has the necessary permissions to create a runtime in Colab Enterprise, ask your administrator to grant your user account the Colab Enterprise Admin (roles/aiplatform.colabEnterpriseAdmin) IAM role on the project. For more information about granting roles, see Manage access to projects, folders, and organizations.

Your administrator might also be able to give your user account the required permissions through custom roles or other predefined roles.

Create a runtime

To create a runtime:

Console

  1. In the Google Cloud console, go to the Colab Enterprise Runtimes page.

    Go to Runtimes

  2. In the Region menu, select the region where you want your runtime. It must be in the same region as the notebook that uses it.

  3. Click  Create runtime.

    The Create Vertex AI runtime dialog appears.

  4. In the Runtime template menu, select a runtime template. If there aren't any runtime templates listed, create a runtime template.

  5. In the Runtime name field, enter a name for your runtime.

  6. Click Create.

gcloud

Before using any of the command data below, make the following replacements:

  • PROJECT_ID: your project ID.
  • REGION: the region to create your runtime in.
  • DISPLAY_NAME: the display name for your runtime.
  • RUNTIME_TEMPLATE: the ID of the template to configure the runtime from.
  • Execute the following command:

    Linux, macOS, or Cloud Shell

      gcloud colab runtimes create --display-name=DISPLAY_NAME --runtime-template=RUNTIME_TEMPLATE --project=PROJECT_ID --region=REGION

    Windows (PowerShell)

      gcloud colab runtimes create --display-name=DISPLAY_NAME --runtime-template=RUNTIME_TEMPLATE --project=PROJECT_ID --region=REGION

    Windows (cmd.exe)

      gcloud colab runtimes create --display-name=DISPLAY_NAME --runtime-template=RUNTIME_TEMPLATE --project=PROJECT_ID --region=REGION

    For more information about the command for creating a runtime from the command line, see the gcloud CLI documentation.

    By default, when you create a runtime, you automatically have the required permissions to delete and start that runtime.

    Start a runtime

    To start a runtime:

    Console

    1. In the Google Cloud console, go to the Colab Enterprise Runtimes page.

      Go to Runtimes

    2. In the Region menu, select the region that contains your runtime.

    3. Select the runtime that you want to start.

    4. Click Start.

    gcloud

    Before using any of the command data below, make the following replacements:

  • RUNTIME: the ID of your runtime.
  • PROJECT_ID: your project ID.
  • REGION: the region where your runtime is located.
  • Execute the following command:

    Linux, macOS, or Cloud Shell

    gcloud colab runtimes start RUNTIME --project=PROJECT_ID --region=REGION

    Windows (PowerShell)

    gcloud colab runtimes start RUNTIME --project=PROJECT_ID --region=REGION

    Windows (cmd.exe)

    gcloud colab runtimes start RUNTIME --project=PROJECT_ID --region=REGION

    For more information about the command for starting a runtime from the command line, see the gcloud CLI documentation.

    Delete a runtime

    To delete a runtime:

    Console

    1. In the Google Cloud console, go to the Colab Enterprise Runtimes page.

      Go to Runtimes

    2. In the Region menu, select the region that contains your runtime.

    3. Select the runtime that you want to delete.

    4. Click  Delete.

    5. Click Confirm.

    gcloud

    Before using any of the command data below, make the following replacements:

  • PROJECT_ID: your project ID.
  • REGION: the region where your runtime is located.
  • RUNTIME: the ID of your runtime.
  • Execute the following command:

    Linux, macOS, or Cloud Shell

    gcloud colab runtimes delete RUNTIME --project=PROJECT_ID --region=REGION

    Windows (PowerShell)

    gcloud colab runtimes delete RUNTIME --project=PROJECT_ID --region=REGION

    Windows (cmd.exe)

    gcloud colab runtimes delete RUNTIME --project=PROJECT_ID --region=REGION

    For more information about the command for deleting a runtime template from the command line, see the gcloud CLI documentation.

    Troubleshoot

    This section shows you how to resolve issues with creating runtimes in Colab Enterprise.

    Unable to create a runtime

    This issue occurs when you're unable to create a runtime. See also Unable to create a default runtime. The most common causes are:

    Insufficient quota

    If you are unable to create a runtime, you might have exceeded your Compute Engine runtime quota.

    Colab Enterprise uses Compute Engine quota for runtimes. For more information, see the Compute Engine quota and limits overview.

    To resolve this issue, request a higher quota limit.

    Unavailable resources

    The following error occurs when you try to create a runtime.

    No available zone found for runtime RUNTIME_ID
    for machine type MACHINE_TYPE
    with accelerator type: ACCELERATOR. Please try again later.
    

    This error occurs if there are no resources available for your machine type configuration within your notebook's region.

    To resolve this issue, try a runtime with a different machine type configuration, or try again at a later time.

    Default runtime already exists

    The following error occurs when you try to create a runtime from the default runtime template when the default runtime already exists.

    Failed to create runtime
    
    One click runtime already exists.
    

    If you try to create a runtime from a default runtime template, Colab Enterprise tries to create a default runtime. There can only be one default runtime per user, project, and region. If the default runtime already exists, Colab Enterprise is unable to create another default runtime.

    To resolve this issue, connect to the existing default runtime or create a runtime from a non-default runtime template.

    Unable to create a default runtime

    When Colab Enterprise creates a default runtime, it first creates a default runtime template that it uses to generate the default runtime. If you try to create a default runtime without the permissions required to create a runtime template, then Colab Enterprise can't create the default runtime.

    To resolve this issue, ask your administrator to grant you a role that includes the aiplatform.notebookRuntimeTemplates.create permission.

    What's next