Skip to content

Publish main to live, 07/09, 3:30 PM IST #3845

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 53 commits into from
Jul 9, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
53 commits
Select commit Hold shift + click to select a range
e9c7649
Updated VMHostAssignableDevice command set
Xelu86 Jun 18, 2024
196cf3a
Updated VMAssignablePartitionableGpu command set
Xelu86 Jun 18, 2024
adad7bc
Updated VMGpuPartitionAdapter command set
Xelu86 Jun 18, 2024
eb2401f
Minor edit
Xelu86 Jun 18, 2024
af6afb7
Update ComputerName description
Xelu86 Jul 3, 2024
4186c30
Applied feedback for Dismount cmdlet
Xelu86 Jul 3, 2024
ee33921
Update ComputerName for Get cmdlet
Xelu86 Jul 3, 2024
92ecded
2nd pass of VMHostAssignableDevice cmdlets
Xelu86 Jul 3, 2024
36debb2
Updated command set
Xelu86 Jul 8, 2024
ec3f12c
Updated command set
Xelu86 Jul 8, 2024
2da3da6
Updated command set
Xelu86 Jul 8, 2024
ffff4e3
Minor edit
Xelu86 Jul 8, 2024
42157ad
Removed Example 2 as it belongs to another cmdlet
Xelu86 Jul 8, 2024
a64971e
Updated command set
Xelu86 Jul 8, 2024
0f66787
Fixing indents
Xelu86 Jul 8, 2024
2c4d896
Fixing indents
Xelu86 Jul 8, 2024
df69d6c
Fixing indents
Xelu86 Jul 8, 2024
4e920c0
Updated Hyper-V cmdlet list
Xelu86 Jul 8, 2024
7a6c90a
Merge branch 'update_vmassdev' of https://github.com/Xelu86/windows-p…
Xelu86 Jul 8, 2024
fbc89c6
Merge branch 'main' into update_vmgpupartitionadapter
Xelu86 Jul 8, 2024
34abebf
Merge branch 'main' into update_vmhostassignabledevice
Xelu86 Jul 8, 2024
c4bce11
Merge branch 'main' into update_vmhostpartitionablegpu
Xelu86 Jul 8, 2024
0a47683
Merge branch 'main' into update_vmassdev
Xelu86 Jul 8, 2024
07ee109
Merge branch 'main' into update_vmhostpartgpu
Xelu86 Jul 8, 2024
ddc09c5
Merge branch 'main' into update_vmgpupartada
Xelu86 Jul 8, 2024
ae8afed
Merge branch 'main' into update_vmhostassdev
Xelu86 Jul 8, 2024
8d414e7
Merge pull request #3823 from Xelu86/update_vmgpupartitionadapter
Xelu86 Jul 8, 2024
ccd2c76
Merge branch 'main' into update_vmhostpartgpu
Xelu86 Jul 8, 2024
4f346d1
Merge branch 'main' into update_vmhostpartitionablegpu
Xelu86 Jul 8, 2024
1184ad1
Merge branch 'main' into update_vmgpupartada
Xelu86 Jul 8, 2024
d44415d
Merge branch 'main' into update_vmhostassdev
Xelu86 Jul 8, 2024
f546d15
Merge branch 'main' into update_vmassdev
Xelu86 Jul 8, 2024
cbbe674
Merge branch 'main' into update_vmhostassignabledevice
Xelu86 Jul 8, 2024
4d917b5
Merge pull request #3841 from Xelu86/update_vmhostpartgpu
Xelu86 Jul 8, 2024
49fd3d8
Merge branch 'main' into update_vmhostpartitionablegpu
Xelu86 Jul 8, 2024
6b84125
Merge branch 'main' into update_vmhostassdev
Xelu86 Jul 8, 2024
422d2c8
Merge branch 'main' into update_vmhostassignabledevice
Xelu86 Jul 8, 2024
e30f07d
Merge branch 'main' into update_vmassdev
Xelu86 Jul 8, 2024
2e938c9
Merge pull request #3822 from Xelu86/update_vmhostpartitionablegpu
Xelu86 Jul 8, 2024
0d398e7
Merge branch 'main' into update_vmhostassdev
Xelu86 Jul 8, 2024
c823759
Merge branch 'main' into update_vmgpupartada
Xelu86 Jul 8, 2024
c0833d4
Merge branch 'main' into update_vmassdev
Xelu86 Jul 8, 2024
7547438
Merge branch 'main' into update_vmhostassignabledevice
Xelu86 Jul 8, 2024
4eeec28
Merge pull request #3820 from Xelu86/update_vmhostassignabledevice
Xelu86 Jul 8, 2024
c43f887
Merge branch 'main' into update_vmassdev
Xelu86 Jul 8, 2024
fdb5b05
Merge branch 'main' into update_vmgpupartada
Xelu86 Jul 8, 2024
c11ed4b
Merge branch 'main' into update_vmhostassdev
Xelu86 Jul 9, 2024
559f93f
Merge pull request #3842 from Xelu86/update_vmgpupartada
Xelu86 Jul 9, 2024
69447d2
Merge branch 'main' into update_vmassdev
Xelu86 Jul 9, 2024
2510929
Merge branch 'main' into update_vmhostassdev
Xelu86 Jul 9, 2024
d5c42c3
Merge pull request #3844 from Xelu86/update_vmhostassdev
Xelu86 Jul 9, 2024
ac6e6f9
Merge branch 'main' into update_vmassdev
Xelu86 Jul 9, 2024
f94da72
Merge pull request #3843 from Xelu86/update_vmassdev
Xelu86 Jul 9, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
111 changes: 79 additions & 32 deletions docset/winserver2022-ps/hyper-v/Add-VMGpuPartitionAdapter.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
description: Adds a GPU partition adapter to a virtual machine.
external help file: Microsoft.HyperV.PowerShell.Cmdlets.dll-Help.xml
Module Name: Hyper-V
ms.date: 09/22/2022
ms.date: 06/12/2024
online version: https://learn.microsoft.com/powershell/module/hyper-v/add-vmgpupartitionadapter?view=windowsserver2022-ps&wt.mc_id=ps-gethelp
schema: 2.0.0
title: Add-VMGpuPartitionAdapter
Expand All @@ -16,53 +16,62 @@ Adds a GPU partition adapter to a virtual machine.
## SYNTAX

### VMName (Default)

```
Add-VMGpuPartitionAdapter [-CimSession <CimSession[]>] [-ComputerName <String[]>]
[-Credential <PSCredential[]>] [-VMName] <String[]> [-Passthru] [-InstancePath <String>]
[-MinPartitionVRAM <UInt64>] [-MaxPartitionVRAM <UInt64>] [-OptimalPartitionVRAM <UInt64>]
[-MinPartitionEncode <UInt64>] [-MaxPartitionEncode <UInt64>] [-OptimalPartitionEncode <UInt64>]
[-MinPartitionDecode <UInt64>] [-MaxPartitionDecode <UInt64>] [-OptimalPartitionDecode <UInt64>]
[-MinPartitionCompute <UInt64>] [-MaxPartitionCompute <UInt64>] [-OptimalPartitionCompute <UInt64>] [-WhatIf]
[-Confirm] [<CommonParameters>]
[-MinPartitionCompute <UInt64>] [-MaxPartitionCompute <UInt64>] [-OptimalPartitionCompute <UInt64>]
[-WhatIf] [-Confirm] [<CommonParameters>]
```

### VMObject

```
Add-VMGpuPartitionAdapter [-VM] <VirtualMachine[]> [-Passthru] [-InstancePath <String>]
[-MinPartitionVRAM <UInt64>] [-MaxPartitionVRAM <UInt64>] [-OptimalPartitionVRAM <UInt64>]
[-MinPartitionEncode <UInt64>] [-MaxPartitionEncode <UInt64>] [-OptimalPartitionEncode <UInt64>]
[-MinPartitionDecode <UInt64>] [-MaxPartitionDecode <UInt64>] [-OptimalPartitionDecode <UInt64>]
[-MinPartitionCompute <UInt64>] [-MaxPartitionCompute <UInt64>] [-OptimalPartitionCompute <UInt64>] [-WhatIf]
[-Confirm] [<CommonParameters>]
[-MinPartitionCompute <UInt64>] [-MaxPartitionCompute <UInt64>] [-OptimalPartitionCompute <UInt64>]
[-WhatIf] [-Confirm] [<CommonParameters>]
```

## DESCRIPTION
The 'Add-VMGpuPartitionAdapter' cmdlet adds a GPU partition adapter to a virtual machine. With no parameter, it assigns a full partition from an assignable GPU to a VM.

The `Add-VMGpuPartitionAdapter` cmdlet adds a GPU partition adapter to a virtual machine. With no
parameter, it assigns a full partition from an assignable GPU to a VM.

## EXAMPLES

### Example 1

```powershell
$vm = Get-VM -name "TestVM"
$vm = Get-VM -Name "TestVM"
Add-VMGpuPartitionAdapter -VM $vm
```

This example assigns a partition to a specific VM object.

### Example 2

```powershell
$vm = Get-VM -name "TestVM"
Add-VMGpuPartitionAdapter -VM $vm -Instancepath "SampleGPUInstancePath"
$vm = Get-VM -Name "TestVM"
Add-VMGpuPartitionAdapter -VM $vm -InstancePath "GPUInstancePath"
```

This example assigns a partition from a specific GPU to a VM where the instance path is the GPU device ID name on the host.
This example assigns a partition from a specific GPU to a VM where the instance path is the GPU
device ID name on the host.

## PARAMETERS

### -CimSession
Runs the cmdlet in a remote session or on a remote computer.
Enter a computer name or a session object, such as the output of a [New-CimSession](https://go.microsoft.com/fwlink/p/?LinkId=227967) or [Get-CimSession](https://go.microsoft.com/fwlink/p/?LinkId=227966) cmdlet.
The default is the current session on the local computer.

Runs the cmdlet in a remote session or on a remote computer. Enter a computer name or a session
object, such as the output of a [New-CimSession](/powershell/module/cimcmdlets/new-cimsession)
or [Get-CimSession](/powershell/module/cimcmdlets/get-cimsession) cmdlet. The default is the
current session on the local computer.

```yaml
Type: CimSession[]
Expand All @@ -77,10 +86,10 @@ Accept wildcard characters: False
```

### -ComputerName
Specifies one or more Hyper-V hosts from which virtual machines are to be retrieved.
NetBIOS names, IP addresses, and fully qualified domain names are allowable.
The default is the local computer.
Use localhost or a dot ('.') to specify the local computer explicitly.

Specifies one or more Hyper-V hosts from which virtual machines are to be retrieved. NetBIOS names,
IP addresses, and fully qualified domain names are allowable. The default is the local computer.
Use localhost or a dot (`.`) to specify the local computer explicitly.

```yaml
Type: String[]
Expand All @@ -95,8 +104,9 @@ Accept wildcard characters: False
```

### -Credential
Specifies one or more user accounts that have permission to perform this action.
The default is the current user.

Specifies one or more user accounts that have permission to perform this action. The default is the
current user.

```yaml
Type: PSCredential[]
Expand All @@ -111,7 +121,9 @@ Accept wildcard characters: False
```

### -InstancePath
Represents the Device Instance path of a GPU in the host. This value can be obtained from the "Name" property of the command 'Get-VMHostPartitionableGpu'.

Represents the Device Instance path of a GPU in the host. This value can be obtained from the
"Name" property of the command `Get-VMHostPartitionableGpu`.

```yaml
Type: String
Expand All @@ -126,7 +138,9 @@ Accept wildcard characters: False
```

### -MaxPartitionCompute
The maximum number of compute assigned by the host GPU. This is defined by the manufacturer's driver.

The maximum number of compute assigned by the host GPU. This is defined by the manufacturer's
driver.

```yaml
Type: UInt64
Expand All @@ -141,7 +155,9 @@ Accept wildcard characters: False
```

### -MaxPartitionDecode
The maximum number of decoders assigned by the host GPU. This is defined by the manufacturer's driver.

The maximum number of decoders assigned by the host GPU. This is defined by the manufacturer's
driver.

```yaml
Type: UInt64
Expand All @@ -156,7 +172,9 @@ Accept wildcard characters: False
```

### -MaxPartitionEncode
The maximum number of encoders assigned by the host GPU. This is defined by the manufacturer's driver.

The maximum number of encoders assigned by the host GPU. This is defined by the manufacturer's
driver.

```yaml
Type: UInt64
Expand All @@ -171,6 +189,7 @@ Accept wildcard characters: False
```

### -MaxPartitionVRAM

The maximum VRAM in bytes supported by the host GPU. This is defined by the manufacturer's driver.

```yaml
Expand All @@ -186,7 +205,9 @@ Accept wildcard characters: False
```

### -MinPartitionCompute
The minimum number of compute assigned by the host GPU. This is defined by the manufacturer's driver.

The minimum number of compute assigned by the host GPU. This is defined by the manufacturer's
driver.

```yaml
Type: UInt64
Expand All @@ -201,7 +222,9 @@ Accept wildcard characters: False
```

### -MinPartitionDecode
The minimum number of decoders assigned by the host GPU. This is defined by the manufacturer's driver.

The minimum number of decoders assigned by the host GPU. This is defined by the manufacturer's
driver.

```yaml
Type: UInt64
Expand All @@ -216,7 +239,9 @@ Accept wildcard characters: False
```

### -MinPartitionEncode
The minimum number of encoders assigned by the host GPU. This is defined by the manufacturer's driver.

The minimum number of encoders assigned by the host GPU. This is defined by the manufacturer's
driver.

```yaml
Type: UInt64
Expand All @@ -231,6 +256,7 @@ Accept wildcard characters: False
```

### -MinPartitionVRAM

The minimum VRAM in bytes supported by the host GPU. This is defined by the manufacturer's driver.

```yaml
Expand All @@ -246,7 +272,9 @@ Accept wildcard characters: False
```

### -OptimalPartitionCompute
The optimal number of compute assigned by the host GPU. This is defined by the manufacturer's driver.

The optimal number of compute assigned by the host GPU. This is defined by the manufacturer's
driver.

```yaml
Type: UInt64
Expand All @@ -261,7 +289,9 @@ Accept wildcard characters: False
```

### -OptimalPartitionDecode
The optimal number of decoders assigned by the host GPU. This is defined by the manufacturer's driver.

The optimal number of decoders assigned by the host GPU. This is defined by the manufacturer's
driver.

```yaml
Type: UInt64
Expand All @@ -276,7 +306,9 @@ Accept wildcard characters: False
```

### -OptimalPartitionEncode
The optimal number of encoders assigned by the host GPU. This is defined by the manufacturer's driver.

The optimal number of encoders assigned by the host GPU. This is defined by the manufacturer's
driver.

```yaml
Type: UInt64
Expand All @@ -291,6 +323,7 @@ Accept wildcard characters: False
```

### -OptimalPartitionVRAM

The optimal VRAM in bytes supported by the host GPU. This is defined by the manufacturer's driver.

```yaml
Expand All @@ -306,6 +339,7 @@ Accept wildcard characters: False
```

### -Passthru

Returns an object for each process that the cmdlet started.

```yaml
Expand All @@ -321,6 +355,7 @@ Accept wildcard characters: False
```

### -VM

Specifies the virtual machine on which the network adapter is to be added.

```yaml
Expand All @@ -336,6 +371,7 @@ Accept wildcard characters: False
```

### -VMName

Specifies the name of the virtual machine on which the network adapter is to be added.

```yaml
Expand All @@ -351,6 +387,7 @@ Accept wildcard characters: False
```

### -Confirm

Prompts you for confirmation before running the cmdlet.

```yaml
Expand All @@ -366,8 +403,8 @@ Accept wildcard characters: False
```

### -WhatIf
Shows what would happen if the cmdlet runs.
The cmdlet is not run.

Shows what would happen if the cmdlet runs. The cmdlet is not run.

```yaml
Type: SwitchParameter
Expand All @@ -382,7 +419,11 @@ Accept wildcard characters: False
```

### CommonParameters
This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](https://go.microsoft.com/fwlink/?LinkID=113216).

This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable,
-InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose,
-WarningAction, and -WarningVariable. For more information, see
[about_CommonParameters](/powershell/module/microsoft.powershell.core/about/about_commonparameters).

## INPUTS

Expand All @@ -397,3 +438,9 @@ This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable
## NOTES

## RELATED LINKS

[Get-VMGpuPartitionAdapter](get-vmgpupartitionadapter.md)

[Remove-VMGpuPartitionAdapter](remove-vmgpupartitionadapter.md)

[Set-VMGpuPartitionAdapter](set-vmgpupartitionadapter.md)
Loading