< Back
Set-VDBlockedPolicy
Post
NAME Set-VDBlockedPolicy
SYNOPSIS
This cmdlet modifies the blocking policy for distributed ports.
SYNTAX
Set-VDBlockedPolicy [-Policy] <BlockedPolicy[]> [-Blocked <Boolean>] [-BlockedInherited <Boolean>] [-Confirm]
[-WhatIf] [<CommonParameters>]
DESCRIPTION
This cmdlet modifies the blocking policy for distributed ports at switch, port group, or port level (depending on
the input policy).
PARAMETERS
-Blocked <Boolean>
Specifies whether packet forwarding is stopped for the corresponding distributed port, port group, or switch.
Required? false
Position? named
Default value None
Accept pipeline input? False
Accept wildcard characters? false
-BlockedInherited <Boolean>
Specifies whether the Blocked setting is inherited from a parent object, such as a distributed port group or
switch.
Required? false
Position? named
Default value None
Accept pipeline input? False
Accept wildcard characters? false
-Policy <BlockedPolicy[]>
Specifies the blocking policy that you want to configure.
Required? true
Position? 2
Default value None
Accept pipeline input? True (ByValue)
Accept wildcard characters? false
-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.
Required? false
Position? named
Default value False
Accept pipeline input? False
Accept wildcard characters? false
-WhatIf [<SwitchParameter>]
Indicates that the cmdlet is run only to display the changes that would be made and actually no objects are
modified.
Required? false
Position? named
Default value False
Accept pipeline input? False
Accept wildcard characters? false
<CommonParameters>
This cmdlet supports the common parameters: Verbose, Debug,
ErrorAction, ErrorVariable, WarningAction, WarningVariable,
OutBuffer, PipelineVariable, and OutVariable. For more information, see
about_CommonParameters (https:/go.microsoft.com/fwlink/?LinkID=113216).
INPUTS
OUTPUTS
The modified BlockedPolicy objects
NOTES
-------------------------- Example 1 --------------------------
Get-VDPort -VDSwitch "MyVDSwitch" -ActiveOnly | Get-VDBlockedPolicy | Set-VDBlockedPolicy -Blocked
Retrieves all active distributed ports and updates their blocking policy to stop packet forwarding through them.
-------------------------- Example 2 --------------------------
Get-VDportgroup "MyVDPortgroup" | Get-VDPort | Get-VDBlockedPolicy | Set-VDBlockedPolicy -BlockedInherited
Retrieves the specified "MyVDPortgroup" distributed port group and updates the blocking policy of all ports inside
the group to inherit the setting for packet forwarding from the one set on the distributed port group level.
RELATED LINKS
Online Version: https://code.vmware.com/doc/preview?id= ... olicy.html
Get-VDBlockedPolicy
SYNOPSIS
This cmdlet modifies the blocking policy for distributed ports.
SYNTAX
Set-VDBlockedPolicy [-Policy] <BlockedPolicy[]> [-Blocked <Boolean>] [-BlockedInherited <Boolean>] [-Confirm]
[-WhatIf] [<CommonParameters>]
DESCRIPTION
This cmdlet modifies the blocking policy for distributed ports at switch, port group, or port level (depending on
the input policy).
PARAMETERS
-Blocked <Boolean>
Specifies whether packet forwarding is stopped for the corresponding distributed port, port group, or switch.
Required? false
Position? named
Default value None
Accept pipeline input? False
Accept wildcard characters? false
-BlockedInherited <Boolean>
Specifies whether the Blocked setting is inherited from a parent object, such as a distributed port group or
switch.
Required? false
Position? named
Default value None
Accept pipeline input? False
Accept wildcard characters? false
-Policy <BlockedPolicy[]>
Specifies the blocking policy that you want to configure.
Required? true
Position? 2
Default value None
Accept pipeline input? True (ByValue)
Accept wildcard characters? false
-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.
Required? false
Position? named
Default value False
Accept pipeline input? False
Accept wildcard characters? false
-WhatIf [<SwitchParameter>]
Indicates that the cmdlet is run only to display the changes that would be made and actually no objects are
modified.
Required? false
Position? named
Default value False
Accept pipeline input? False
Accept wildcard characters? false
<CommonParameters>
This cmdlet supports the common parameters: Verbose, Debug,
ErrorAction, ErrorVariable, WarningAction, WarningVariable,
OutBuffer, PipelineVariable, and OutVariable. For more information, see
about_CommonParameters (https:/go.microsoft.com/fwlink/?LinkID=113216).
INPUTS
OUTPUTS
The modified BlockedPolicy objects
NOTES
-------------------------- Example 1 --------------------------
Get-VDPort -VDSwitch "MyVDSwitch" -ActiveOnly | Get-VDBlockedPolicy | Set-VDBlockedPolicy -Blocked
Retrieves all active distributed ports and updates their blocking policy to stop packet forwarding through them.
-------------------------- Example 2 --------------------------
Get-VDportgroup "MyVDPortgroup" | Get-VDPort | Get-VDBlockedPolicy | Set-VDBlockedPolicy -BlockedInherited
Retrieves the specified "MyVDPortgroup" distributed port group and updates the blocking policy of all ports inside
the group to inherit the setting for packet forwarding from the one set on the distributed port group level.
RELATED LINKS
Online Version: https://code.vmware.com/doc/preview?id= ... olicy.html
Get-VDBlockedPolicy