All Products
Search
Document Center

Elastic Container Instance:Create a pod with a specific GPU type

Last Updated:Mar 25, 2026

This topic describes how to create an Elastic Container Instance (ECI) pod with a specific Elastic Compute Service (ECS) GPU-accelerated instance type and change the GPU driver version.

Supported instance types

GPU-accelerated instance types are suitable for scenarios such as deep learning and image editing. You can run Docker images for GPUs directly on ECI GPU-accelerated instances. A NVIDIA graphics card driver is pre-installed in each instance. The supported driver and CUDA versions vary by GPU instance type.

Note

The gn8ia and gn8is instance families in the following table are available only in some regions outside China. To use these instance families, contact Alibaba Cloud sales.

Category

GPU instance family

Driver and CUDA versions

vGPU-accelerated instance family

sgn7i-vws

GRID 470, CUDA 11.4 (default)

vgn7i-vws

vgn6i-vws

GPU-accelerated compute-optimized instance family

gn7e

  • Tesla 470, CUDA 11.4 (default)

  • Tesla 535, CUDA 12.2

  • Tesla 550, CUDA 12.4

gn7i

gn7s

gn7

gn6v

gn6e

gn6i

gn5i

gn5

gn8ia

  • Tesla 535, CUDA 12.2 (default)

  • Tesla 550, CUDA 12.2

gn8is

Important

Starting March 17, 2025, specify only the major version number for GPU drivers, such as 535, instead of the full version number, such as 535.161.08. The created instance will use a driver with the specified major version, but the minor version may be updated. When an older driver is unpublished, a newer version is automatically used to create the instance. The support period for a driver version aligns with NVIDIA's official support. For more information, see NVIDIA Driver Documentation.

GPU driver update history

Update time

Update description

March 2025

  • The GRID 470 driver is updated to 470.239.06.

  • The Tesla 470 driver is updated to 470.256.02, the Tesla 535 driver is updated to 535.230.02, and the Tesla 550 driver is updated to 550.127.08.

  • The Tesla 525 driver is no longer supported. If you specify this driver, the system falls back to version 535.

For more information about ECS instance types, see the following topics:

Configuration

Add the k8s.aliyun.com/eci-use-specs annotation to the pod metadata to specify a GPU instance type. After specifying the instance type, you must add the nvidia.com/gpu field in the resources section of a container to request GPU resources.

Important
  • The nvidia.com/gpu field specifies the number of GPUs the container requires. You must specify this field when you create a GPU pod. If this field is not specified, pod creation will fail.

  • By default, multiple containers can share GPUs. Make sure that the number of GPUs configured for a single container does not exceed the total number of GPUs in the specified instance type.

The following is a sample YAML file:

apiVersion: apps/v1
kind: Deployment
metadata:
  name: test
  labels:
    app: test
spec:
  replicas: 2
  selector:
    matchLabels:
      app: nginx
  template:
    metadata:
      name: nginx-test
      labels:
        app: nginx
        alibabacloud.com/eci: "true" 
      annotations:
        # Specify up to five GPU-accelerated ECS instance types at a time, separated by commas. 
        # The system selects the first available type from the list.
        k8s.aliyun.com/eci-use-specs: "ecs.gn6i-c4g1.xlarge,ecs.gn6i-c8g1.2xlarge"
    spec:
      containers:
      - name: nginx
        image: registry-us-east-1.aliyuncs.com/eci_open/nginx:1.14.2
        resources:
            limits:
              nvidia.com/gpu: "1"    # Request 1 GPU for this container (GPUs are shared by default).
        ports:
        - containerPort: 80
      - name: busybox
        image: registry-us-east-1.aliyuncs.com/eci_open/busybox:1.30
        command: ["sleep"]
        args: ["999999"]
        resources:
            limits:
              nvidia.com/gpu: "1"    # Request 1 GPU for this container (GPUs are shared by default).

By default, an ECI GPU instance automatically installs a supported driver and CUDA version based on the specified GPU instance type. If your workload requires a different driver version, you can add the k8s.aliyun.com/eci-gpu-driver-version annotation to specify the driver version.

For example, if you specify the ecs.gn6i-c4g1.xlarge instance type, the default driver is Tesla 550 and the default CUDA version is 12.4. Adding the k8s.aliyun.com/eci-gpu-driver-version: tesla=535 annotation changes the driver to Tesla 535 and the CUDA version to 12.2. The following is a sample YAML file:

apiVersion: apps/v1
kind: Deployment
metadata:
  name: test
  labels:
    app: test
spec:
  replicas: 1
  selector:
    matchLabels:
      app: nginx
  template:
    metadata:
      name: nginx-test
      labels:
        app: nginx
        alibabacloud.com/eci: "true" 
      annotations:
        # Specify a supported GPU instance type that allows you to change the driver version.
        k8s.aliyun.com/eci-use-specs: ecs.gn6i-c4g1.xlarge
        # Override the default driver version (Tesla 550) with Tesla 535.
        k8s.aliyun.com/eci-gpu-driver-version: tesla=535
    spec:
      containers:
      - name: nginx
        image: registry-us-east-1.aliyuncs.com/eci_open/nginx:1.14.2
        resources:
            limits:
              nvidia.com/gpu: "1"    # Request 1 GPU for this container.