Set-SCLogicalSwitch
Updates the properties of a logical switch.
Syntax
Set-SCLogicalSwitch
[-VirtualSwitchExtensions <VirtualSwitchExtension[]>]
[-Description <String>]
[-EnableSriov <Boolean>]
[-SwitchUplinkMode <SwitchUplinkMode>]
[-MinimumBandwidthMode <BandwidthMode>]
[-VMMServer <ServerConnection>]
[-LogicalSwitch] <LogicalSwitch>
[-Name <String>]
[-EnablePacketDirect <Boolean>]
[-RunAsynchronously]
[-PROTipID <Guid>]
[-JobVariable <String>]
[<CommonParameters>]
Set-SCLogicalSwitch
[-Description <String>]
[-EnableSriov <Boolean>]
[-SwitchUplinkMode <SwitchUplinkMode>]
[-MinimumBandwidthMode <BandwidthMode>]
[-VMMServer <ServerConnection>]
[-LogicalSwitch] <LogicalSwitch>
[-RemoveAllExtensions]
[-Name <String>]
[-EnablePacketDirect <Boolean>]
[-RunAsynchronously]
[-PROTipID <Guid>]
[-JobVariable <String>]
[<CommonParameters>]
Description
The Set-SCLogicalSwitch cmdlet updates the properties of a logical switch.
Examples
Example 1: Change the minimum bandwidth mode for a logical switch
PS C:\> Get-SCLogicalSwitch -Name "LogicalSwitch01" | Set-SCLogicalSwitch -MinimumBandwidthMode "Weight"
This command gets the logical switch object named LogicalSwitch01 and uses the pipeline operator to pass the object to Set-SCLogicalSwitch, which changes the minimum bandwitdth mode for logical switch object to Weight.
Example 2: Remove all virtual switch extensions from a logical switch
PS C:\> Get-SCLogicalSwitch -Name "LogicalSwitch01" | Set-SCLogicalSwitch -RemoveAllExtensions
This command gets the logical switch object named LogicalSwitch01 and uses the pipeline operator to pass the object to Set-SCLogicalSwitch, which removes all virtual switch extensions from the logical switch object.
Parameters
-Description
Specifies a description for the specified object.
Type: | String |
Position: | Named |
Default value: | None |
Required: | False |
Accept pipeline input: | False |
Accept wildcard characters: | False |
-EnablePacketDirect
Specifies whether the cmdlet enables Packet Direct on the switch.
Type: | Boolean |
Position: | Named |
Default value: | None |
Required: | False |
Accept pipeline input: | False |
Accept wildcard characters: | False |
-EnableSriov
Indicates whether single-root I/O virtualization (SR-IOV) is enabled.
Type: | Boolean |
Position: | Named |
Default value: | None |
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 |
-LogicalSwitch
Specifies a logical switch object.
Type: | LogicalSwitch |
Position: | 0 |
Default value: | None |
Required: | True |
Accept pipeline input: | True |
Accept wildcard characters: | False |
-MinimumBandwidthMode
Specifies the minimum bandwidth mode for the logical switch. The acceptable values for this parameter are:
- Default
- Weight
- Absolute
- None
Type: | BandwidthMode |
Accepted values: | Default, Weight, Absolute, None |
Position: | Named |
Default value: | None |
Required: | False |
Accept pipeline input: | False |
Accept wildcard characters: | False |
-Name
Specifies the name of a Virtual Machine Manager (VMM) object.
Type: | String |
Position: | Named |
Default value: | None |
Required: | False |
Accept pipeline input: | False |
Accept wildcard characters: | False |
-PROTipID
Specifies the ID of the Performance and Resource Optimization (PRO) tip that triggered this action. This allows for auditing of PRO tips.
Type: | Guid |
Position: | Named |
Default value: | None |
Required: | False |
Accept pipeline input: | False |
Accept wildcard characters: | False |
-RemoveAllExtensions
Indicates that all virtual switch extensions are removed from the logical switch.
Type: | SwitchParameter |
Position: | Named |
Default value: | None |
Required: | True |
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 |
-SwitchUplinkMode
Specifies a switch uplink mode object.
Type: | SwitchUplinkMode |
Accepted values: | NoTeam, Team, EmbeddedTeam |
Position: | Named |
Default value: | None |
Required: | False |
Accept pipeline input: | False |
Accept wildcard characters: | False |
-VirtualSwitchExtensions
Specifies an array of virtual switch extension objects.
To get a virtual switch extension object, use the Get-SCVirtualSwitchExtension cmdlet.
Type: | VirtualSwitchExtension[] |
Position: | Named |
Default value: | None |
Required: | False |
Accept pipeline input: | True |
Accept wildcard characters: | False |
-VMMServer
Specifies a VMM server object.
Type: | ServerConnection |
Position: | Named |
Default value: | None |
Required: | False |
Accept pipeline input: | True |
Accept wildcard characters: | False |