Remove-VirtualSwitch
This cmdlet removes the specified virtual switches from their locations.
Syntax
Parameters
Required | Parameter Name | Type | Position | Features | Description |
---|---|---|---|---|---|
required
|
VirtualSwitch | VirtualSwitch[] | named |
|
Specifies the virtual switches you want to remove. |
optional | ProgressAction | ActionPreference | named |
|
|
optional | Server | VIServer[] | named |
|
Specifies the vCenter Server systems on which you want to run the cmdlet. If no value is provided or $null value is passed to this parameter, the command runs on the default servers. For more information about default servers, see the description of Connect-VIServer. |
Output
Examples
Example 1
$vswitch = New-VirtualSwitch -VMHost 10.23.122.145 -Name VirtualSwitch Remove-VirtualSwitch -VirtualSwitch $vswitch
Creates a new virtual switch named VirtualSwitch on the host with an IP address 10.23.122.145. Then removes the virtual switch.
Related Commands
VirtualSwitch
This cmdlet retrieves the virtual switches associated with a virtual machine host or used by a virtual machine.
This cmdlet creates a new virtual switch.
This cmdlet removes the specified virtual switches from their locations.
This cmdlet modifies the properties of the specified virtual switch.
VirtualSwitchPhysicalNetworkAdapter
This cmdlet adds a host physical NIC to a standard virtual switch.
This cmdlet removes the specified host physical NICs from the standard virtual switch.