Remove-SCLogicalSwitchVirtualNetworkAdapter
Removes a virtual network adapter (VNIC) from a logical switch.
Syntax
Remove-SCLogicalSwitchVirtualNetworkAdapter
[-VMMServer <ServerConnection>]
[-LogicalSwitchVirtualNetworkAdapter] <LogicalSwitchVirtualNetworkAdapter>
[-RunAsynchronously]
[-PROTipID <Guid>]
[-JobVariable <String>]
[-WhatIf]
[-Confirm]
[<CommonParameters>]
Description
The Remove-SCLogicalSwitchVirtualNetworkAdapter cmdlet removes a virtual network adapter that was added to the Uplink Port Profile as part of a logical switch definition.
Examples
Example 1: Delete a logical switch virtual network adapter
PS C:\> $HostVNicVarToRemove = Get-SCLogicalSwitchVirtualNetworkAdapter -ID "6615c2c2-4eaa-4f75-be3e-bbdb8cb25ca1"
PS C:\> Remove-SCLogicalSwitchVirtualNetworkAdapter -LogicalSwitchVirtualNetworkAdapter $HostVNicVarToRemove
The first command gets a logical switch virtual network adapter by using the Get-SCLogicalSwitchVirtualNetworkAdapter cmdlet, and then stores it in the $HostVNicVarToRemove variable.
The second command removes the virtual network adapter. It is no longer deployed with the logical switch.
Parameters
-Confirm
Prompts you for confirmation before running the cmdlet.
Type: | SwitchParameter |
Aliases: | cf |
Position: | Named |
Default value: | False |
Required: | False |
Accept pipeline input: | False |
Accept wildcard characters: | False |
-JobVariable
Specifies a variable in which job progress is tracked and stored.
Type: | String |
Position: | Named |
Default value: | None |
Required: | False |
Accept pipeline input: | False |
Accept wildcard characters: | False |
-LogicalSwitchVirtualNetworkAdapter
The virtual network adapter to remove.
Type: | LogicalSwitchVirtualNetworkAdapter |
Position: | 0 |
Default value: | None |
Required: | True |
Accept pipeline input: | True |
Accept wildcard characters: | False |
-PROTipID
Specifies the ID of the Performance and Resource Optimization tip (PRO tip) that triggered this action. This parameter lets you audit PRO tips.
Type: | Guid |
Position: | Named |
Default value: | None |
Required: | False |
Accept pipeline input: | False |
Accept wildcard characters: | False |
-RunAsynchronously
Indicates that the job runs asynchronously so that control returns to the command shell immediately.
Type: | SwitchParameter |
Position: | Named |
Default value: | None |
Required: | False |
Accept pipeline input: | False |
Accept wildcard characters: | False |
-VMMServer
Specifies a Virtual Machine Manager (VMM) server object.
Type: | ServerConnection |
Position: | Named |
Default value: | None |
Required: | False |
Accept pipeline input: | True |
Accept wildcard characters: | False |
-WhatIf
Shows what would happen if the cmdlet runs. The cmdlet is not run.
Type: | SwitchParameter |
Aliases: | wi |
Position: | Named |
Default value: | False |
Required: | False |
Accept pipeline input: | False |
Accept wildcard characters: | False |