Overview of creating an instance with attached GPUs (original) (raw)

Linux Windows


Compute Engine provides graphics processing units (GPUs) that you can add to your virtual machines (VMs). You can use these GPUs to accelerate specific workloads on your VMs such as machine learning and data processing.

This document provides an overview of the steps required for creating a VM with attached GPUs.

For more information about GPUs on Compute Engine, seeAbout GPUs.

Select the GPU model

For a list of GPU models that are available, seeGPU platforms. Also make a note of the machine type that is supported for the selected GPU model.

For each model, it might also be helpful to review the following:

Limitations

In addition to therestrictions for all VMs with GPUs, each machine series with attached GPUs has the following limitations:

A4 VMs

A3 Ultra VMs

A3 Mega VMs

A3 High VMs

A3 Edge VMs

A2 Standard VMs

A2 Ultra VMs

G2 VMs

N1+GPU VMs

To learn about the limitations for N1 instances with GPUs, seefeatures for the N1 machine seriesand GPUs for the N1 machine series.

Choose an operating system

If you are using GPUs for machine learning, use one of the following operating systems:

Alternatively, you can use any public imageor custom image. Note that some images might require a unique driver or have an install process that is out of the scope of the Compute Engine documentation. To help identify which drivers are appropriate for your OS image, see installing GPU drivers.

Check GPU quota

To protect Compute Engine systems and users, new projects have a global GPU quota, which limits the total number of GPUs you can create in any supported zone. To review GPU quota, seeGPU quota.

If you need additional GPU quota,request a quota increase. When you request GPU quota, you must request quota for the GPU types that you want to create in each region and an additional global quota for the total number of GPUs of all types in all zones.

If your project has an established billing history, it will receive quota automatically after you submit the request.

GPU VMs and preemptible allocation quotas

VMs that use thestandard provisioning modeltypically can't use preemptible allocation quotas. Preemptible quotas are for temporary workloads and are usually more available. If your project doesn't have preemptible quota, and you have never requested it, then all VMs in your project consume standard allocation quotas.

If you request preemptible allocation quota, then VMs that use the standard provisioning model must meet all of the following criteria to consume preemptible allocation quota:

When you consume preemptible allocation for time-bound GPU workloads, you can benefit from both uninterrupted run time and the high obtainability of preemptible allocation quota. For more information, seePreemptible quotas.

Create a VM that has attached GPUs

To create a VM that has attached GPUs, complete the following steps:

  1. Create the VM. The method used to create a VM depends on the GPU model selected.
  2. For the VM to use the GPU, you need toinstall the GPU driver on your VM. If you enabled an NVIDIA RTX virtual workstation (formerly known as NVIDIA GRID),install a driver for virtual workstation.

What's next?