Skip to content

Commit 338bdf5

Browse files
authored
Merge pull request #15923 from MicrosoftDocs/main
9/25/2024 AM Publish
2 parents 9073c44 + 72aeb9d commit 338bdf5

31 files changed

+688
-12
lines changed
-3.69 KB
Loading
-9 KB
Loading
-33.9 KB
Loading

azure-stack/hci/known-issues-2408-1.md

Lines changed: 105 additions & 0 deletions
Large diffs are not rendered by default.
Lines changed: 82 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,82 @@
1+
---
2+
title: Manage GPUs via Discrete Device Assignment for Azure Stack HCI (preview)
3+
description: Learn how to Manage GPUs via Discrete Device Assignment for Azure Stack HCI (preview).
4+
author: alkohli
5+
ms.author: alkohli
6+
ms.topic: how-to
7+
ms.service: azure-stack
8+
ms.subservice: azure-stack-hci
9+
ms.date: 09/25/2024
10+
---
11+
12+
# Manage GPUs via Discrete Device Assignment (preview)
13+
14+
[!INCLUDE [applies-to](../../includes/hci-applies-to-23h2.md)]
15+
16+
This article describes how to manage GPU DDA with Arc virtual machines (VMs). For GPU DDA management on AKS enabled by Azure Arc, see [Use GPUs for compute-intensive workloads](/azure/aks/hybrid/deploy-gpu-node-pool#create-a-new-workload-cluster-with-a-gpu-enabled-node-pool).
17+
18+
Discrete Device Assignment (DDA) allows you to dedicate a physical graphical processing unit (GPU) to your workload. In a DDA deployment, virtualized workloads run on the native driver and typically have full access to the GPU's functionality. DDA offers the highest level of app compatibility and potential performance.
19+
20+
> [!IMPORTANT]
21+
> This feature is currently in PREVIEW. See the [Supplemental Terms of Use for Microsoft Azure Previews](https://azure.microsoft.com/support/legal/preview-supplemental-terms/) for legal terms that apply to Azure features that are in beta, preview, or otherwise not yet released into general availability.
22+
23+
24+
## Prerequisites
25+
26+
Before you begin, satisfy the following prerequisites:
27+
28+
- Follow the set up instructions found at [Prepare for GPUs for Azure Stack HCI](./gpu-manage-via-device.md) to prepare your Azure Stack HCI cluster and Arc VMs and to ensure that your GPUs are prepared for DDA.
29+
30+
## Attach a GPU during Arc VM creation
31+
32+
Follow the steps outlined in [Create Arc virtual machines on Azure Stack HCI](create-arc-virtual-machines.md?tabs=azurecli) and utilize the additional hardware profile details to add GPU to your create process.
33+
34+
```azurecli
35+
az stack-hci-vm create --name $vmName --resource-group $resource_group --admin-username $userName --admin-password $password --computer-name $computerName --image $imageName --location $location --authentication-type all --nics $nicName --custom-location $customLocationID --hardware-profile memory-mb="8192" processors="4" --storage-path-id $storagePathId --gpus GpuDDA
36+
```
37+
38+
## Attach a GPU after Arc VM creation
39+
40+
Use the following CLI command to attach the GPU:
41+
42+
```azurecli
43+
az stack-hci-vm gpu attach --resource-group "test-rg" --custom-location "test-location" --vm-name "test-vm" --gpus GpuDDA
44+
```
45+
46+
After attaching the GPU, the output shows the full VM details. You can confirm the GPUs were attached by reviewing the hardware profile `virtualMachineGPUs` section - the output looks like this:
47+
48+
```azurecli
49+
"properties":{
50+
"hardwareProfile":{
51+
"virtualMachineGPUs":[
52+
{
53+
"assignmentType": "GpuDDA",
54+
"gpuName": "NVIDIA A2",
55+
"partitionSizeMb": null
56+
}
57+
],
58+
```
59+
60+
For details on the GPU attach command, see [az stack-hci-vm gpu](/cli/azure/stack-hci-vm/gpu).
61+
62+
## Detach a GPU
63+
64+
Use the following CLI command to detach the GPU:
65+
66+
```azurecli
67+
az stack-hci-vm gpu detach --resource-group "test-rg" --custom-location "test-location" --vm-name "test-vm"
68+
```
69+
70+
After detaching the GPU, the output shows the full VM details. You can confirm the GPUs were detached by reviewing the hardware profile `virtualMachineGPUs` section - the output looks like this:
71+
72+
```azurecli
73+
"properties":{
74+
"hardwareProfile":{
75+
"virtualMachineGPUs":[],
76+
```
77+
78+
For details on the GPU attach command, see [az stack-hci-vm gpu](/cli/azure/stack-hci-vm/gpu).
79+
80+
## Next steps
81+
82+
- [Manage GPUs via partitioning](./gpu-manage-via-partitioning.md)
Lines changed: 107 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,107 @@
1+
---
2+
title: Manage GPUs using partitioning for Azure Stack HCI (preview)
3+
description: Learn how to manage GPUs using partitioning Azure Stack HCI (preview).
4+
author: alkohli
5+
ms.author: alkohli
6+
ms.topic: how-to
7+
ms.service: azure-stack
8+
ms.subservice: azure-stack-hci
9+
ms.date: 09/25/2024
10+
---
11+
12+
# Manage GPUs using partitioning (preview)
13+
14+
[!INCLUDE [hci-applies-to-23h2](../../includes/hci-applies-to-23h2.md)]
15+
16+
This article describes how to manage GPU-P with Arc virtual machines (VMs). For using GPU-P management on AKS enabled by Azure Arc, see [Use GPUs for compute-intensive workloads](/azure/aks/hybrid/deploy-gpu-node-pool#create-a-new-workload-cluster-with-a-gpu-enabled-node-pool).
17+
18+
GPU Partitioning (GPU-P) allows you to share a graphical processing unit (GPU) with multiple workloads by splitting the GPU into dedicated fractional partitions.
19+
20+
> [!IMPORTANT]
21+
> This feature is currently in PREVIEW. See the [Supplemental Terms of Use for Microsoft Azure Previews](https://azure.microsoft.com/support/legal/preview-supplemental-terms/) for legal terms that apply to Azure features that are in beta, preview, or otherwise not yet released into general availability.
22+
23+
## Limitations
24+
25+
Consider the following limitations when using the GPU-P feature:
26+
27+
- GPU partitioning is unsupported if your configuration isn't homogeneous. Here are some examples of unsupported configurations:
28+
29+
- Mixing GPUs from different vendors in the same cluster.
30+
31+
- Using different GPU models from different product families from the same vendor in the same cluster.
32+
33+
- You can't assign a physical GPU as both Discrete Device Assignment (DDA) and as partitionable GPU (GPU-P). You can either assign it as DDA or as a partitionable GPU, but not both.
34+
35+
- You can assign only a single GPU partition to a VM.
36+
37+
- Partitions are autoassigned to the VMs. You can't choose a specific partition for a specific VM.
38+
39+
- Currently, GPU partitioning on Azure Stack HCI doesn't support live migration of VMs. But VMs can be automatically restarted and placed where GPU resources are available if there's a failure.
40+
41+
- You can partition your GPU using Azure Command-Line Interface (CLI). We recommend that you use Azure CLI to configure and assign GPU partitions. You must manually ensure that the homogeneous configuration is maintained for GPUs across all the servers in your cluster.
42+
43+
## Prerequisites
44+
45+
- See [Prepare GPUs for Azure Stack HCI](./gpu-manage-via-partitioning.md) for requirements and to prepare your Azure Stack HCI cluster and Arc VMs and to ensure that your GPUs are prepared and partitioned.
46+
47+
## Attach a GPU during Arc VM creation
48+
49+
Follow the steps outlined in [Create Arc virtual machines on Azure Stack HCI](create-arc-virtual-machines.md?tabs=azurecli) and utilize the additional hardware profile details to add GPU to your create process. Run the following:
50+
51+
```azurecli
52+
az stack-hci-vm create --name $vmName --resource-group $resource_group --admin-username $userName --admin-password $password --computer-name $computerName --image $imageName --location $location --authentication-type all --nics $nicName --custom-location $customLocationID --hardware-profile memory-mb="8192" processors="4" --storage-path-id $storagePathId --gpus GpuP
53+
```
54+
55+
For more information, see [az stack-hci-vm create](/cli/azure/stack-hci-vm).
56+
57+
## Attach a GPU after Arc VM creation
58+
59+
Use the following CLI command to attach the GPU:
60+
61+
```azurecli
62+
az stack-hci-vm stop --name your_VM_name --resource-group your_resource_group
63+
```
64+
65+
You can specify the partition size in the command, as shown below. Partition sizes are the same as the `minPartitionVRAM` found in `Get-VMHostPartitionableGpu` on Hyper-V. You can also use the command without specifying the partition size, as seen in the above example.
66+
67+
```azurecli
68+
az stack-hci-vm gpu attach --resource-group "test-rg" --custom-location "test-location" --vm-name "test-vm" --gpus GpuP
69+
```
70+
71+
After attaching the GPU partition, the output will show the full VM details. You can confirm the GPUs were attached by reviewing the hardware profile `virtualMachineGPUs` section. The output will look as follows:
72+
73+
```azurecli
74+
"properties":{
75+
"hardwareProfile":{
76+
"virtualMachineGPUs":[
77+
{
78+
"assignmentType": "GpuP",
79+
"gpuName": null,
80+
"partitionSizeMb": 3648
81+
}
82+
],
83+
```
84+
85+
For more information on the GPU attach command, see [az stack-hci-vm gpu](/cli/azure/stack-hci-vm/gpu).
86+
87+
## Detach a GPU
88+
89+
Use the following CLI command to detach the GPU:
90+
91+
```azurecli
92+
az stack-hci-vm gpu detach --resource-group "test-rg" --custom-location "test-location" --vm-name "test-vm" --gpus GpuP
93+
```
94+
95+
After detaching the GPU partition, the output will show the full VM details. You can confirm the GPUs were detached by reviewing the hardware profile `virtualMachineGPUs`. The output will look as follows:
96+
97+
```azurecli
98+
"properties":{
99+
"hardwareProfile":{
100+
"virtualMachineGPUs":[],
101+
```
102+
103+
For more information on the GPU attach command, see [az stack-hci-vm gpu](/cli/azure/stack-hci-vm/gpu).
104+
105+
## Next steps
106+
107+
- [Manage GPUs using Discrete Device Assignment](./gpu-manage-via-device.md)

0 commit comments

Comments
 (0)