Syntax
Remove-VirtualPortGroup [-VirtualPortGroup] <VirtualPortGroup[]> [-Confirm] [-WhatIf] [<CommonParameters>]Related Commands
Online VersionDetailed Description
This cmdlet removes the specified virtual port groups.Parameters
Name | Type | Description | Required? | Pipeline Input | Default Value |
---|---|---|---|---|---|
VirtualPortGroup | VirtualPortGroup[] | Specifies the virtual port groups you want to remove. | true | True (ByValue) | |
Confirm | SwitchParameter | If the value is $true, indicates that the cmdlet asks for confirmation before running. If the value is $false, the cmdlet runs without asking for user confirmation.. | false | False | |
WhatIf | SwitchParameter | Indicates that the cmdlet is run only to display the changes that would be made and actually no objects are modified. | false | False |
Return Type
NoneNotes
Examples
-------------------------- Example 1 --------------------------
$vswitch = New-VirtualSwitch -VMHost 10.23.112.234 -Name VirtualSwitch $vportgroup = New-VirtualPortGroup -VirtualSwitch $vswitch -Name VPortGroup Remove-VirtualPortGroup -VirtualPortGroup $vportgroup
Creates a new virtual switch named VirtualSwitch and a virtual ports group VPortGroup for this switch. Then removes the virtual ports group.