You need to enable JavaScript to run this app.
Volcengine Kubernetes Engine

Volcengine Kubernetes Engine

Copy page
Download PDF
GPU-accelerated computing instance
Create an instance by specifying an instance family (GPU resource).
Copy page
Download PDF
Create an instance by specifying an instance family (GPU resource).
VCI allows you to specify instance families by using specific annotations, and create GPU-type VCIs by specifying resources.limits.​
Usage limits​
  • When you create a GPU Accelerated instance, different configurations match different VCI instance specifications. For the detailed specification matching logic, see Instance specification normalization.​
Prerequisites​
  • A VPC and its subnet have been created. For details, see Creating VPCs.​
Creating instances by using Kubernetes​
You can create GPU-type VCI pods by adding annotations and specifying resources.limits during the creation of pods or deployments, including Deployments, StatefulSets, Jobs, and CronJobs.​
The following table describes the annotation.​
​
Annotation key​
Annotation sample value​
Description​
Required​
vci.vke.volcengine.com/preferred-instance-family​
vci.ini2​
The instance families of the GPU-accelerated type.​
You also need to specify the resources.limits of the pod. VCI will match instance specifications based on the specification matching logic.​
tip​
  • Billing is performed based on the matched instance specification. For billing descriptions, see Product billing.​
  • You can specify multiple GPU-accelerated instance families (annotation values). Separate multiple instance families with commas (,), and determine the priority by the order in which they are entered. If the higher-priority instance family has no available resources, the lower-priority instance family will be used to create instances.​
Required for this scenario​
vci.vke.volcengine.com/gpu-driver-version​
tesla-470.129.06​
Specify the driver version of the GPU-accelerated instance. The annotation value is in the following format: tesla-{NVIDIA driver version}.​
The available {NVIDIA driver version} varies depending on the GPU-accelerated specifications specified in preferred-instance-family. For details, see Supported GPU driver versions.​
tip​
If you do not specify this annotation, the system automatically specifies the default NVIDIA driver version that corresponds to the selected GPU-accelerated instance family.​
Optional​
​
The following sample code shows how to create a pod.​
​
apiVersion: v1​
kind: Pod​
metadata:​
name: demo-gpu-1 # Pod Name.​
namespace: default # Namespace to which the pods belong.​
annotations:​
vke.volcengine.com/burst-to-vci: enforce # Force the use of VCI.​
vci.vke.volcengine.com/preferred-instance-family: vci.ini2 # Specify the GPU-based instance family.​
vci.vke.volcengine.com/gpu-driver-version: tesla-470.129.06 # Specify the GPU driver for instances.​
spec:​
containers:​
- image: doc-cn-beijing.cr.volces.com/vke/nginx-demo:v1.0 # The address and version of the container image. Replace the value with your actual information. If you need to use a public image, make sure that the cluster can access the public network.​
imagePullPolicy: Always​
name: nginx​
resources:​
requests: # Specify the vCPU, memory, and GPU for containers.​
cpu: 37​
nvidia.com/gpu: 2 # Specify the GPU count (as in native Kubernetes) for containers. You can configure both limits and requests, but the values must be identical.​
limits:​
cpu: 37​
nvidia.com/gpu: 2​
​
tip​
The GPU settings under Pod.spec.container[].resources must align with native Kubernetes capabilities and limitations.​
  • Use <vendor>.com/gpu to specify GPU resources.​
  • The limits option is required.​
  • Both limits and requests can be configured, but their values must be identical.​
  • If the requests option is left empty, Kubernetes will use the limits value as the requests value by default.​
  • GPU cannot be shared and overcommitted.​
  • The number of GPUs must be an integer.​
Using the console​
  1. Install the nvidia-device-plugin add-on in the VCI cluster. For details, see Installing add-ons.​
  1. Specify the following parameters when you create a workload.​
  1. Basic information: Select Volcengine Container Instance for the Computing power type parameter.​
  1. Container configuration: Specify the GPU, memory, and CPU resources in the ResourceQuota section.​
  • Specify the parameter in the red box in the following figure. Set the GPU resource type parameter to Nvidia. Specify other parameters based on your business requirements.​
tip​
The mGPU resource type is not supported in VCI scenarios.​
  • ​​​
  1. Advanced configurations: Configure the instance specifications in the VCI specification settings section. You can use the default instance family or specify a custom instance family.​
  • When specifying instance families, you can select multiple families under the same instance type. Their priority is determined by the order in which they are selected. For details, see Specific specifications. If resources are unavailable in a higher-priority family, VCI uses a lower-priority family to create the instance.​
  • ​​​
Last updated: 2026.09.03 15:56:09