< Back
Remove-NsxSecurityPolicy
Post
NAME Remove-NsxSecurityPolicy
SYNOPSIS
Removes the specified NSX Security Policy.
SYNTAX
Remove-NsxSecurityPolicy [-SecurityPolicy] <XmlElement> [-Confirm] [-force] [-Connection <PSObject>]
[<CommonParameters>]
DESCRIPTION
An NSX Security Policy is a set of Endpoint, firewall, and network
introspection services that can be applied to a security group.
This cmdlet removes the specified Security Policy object.
PARAMETERS
-SecurityPolicy <XmlElement>
Security Policy to Remove.
Required? true
Position? 2
Default value
Accept pipeline input? true (ByValue)
Accept wildcard characters? false
-Confirm [<SwitchParameter>]
Prompt for confirmation. Specify as -confirm:$false to disable confirmation prompt
Required? false
Position? named
Default value True
Accept pipeline input? false
Accept wildcard characters? false
-force [<SwitchParameter>]
Force removal, even if the policy is in use.
Required? false
Position? named
Default value False
Accept pipeline input? false
Accept wildcard characters? false
-Connection <PSObject>
PowerNSX Connection object
Required? false
Position? named
Default value $defaultNSXConnection
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
-------------------------- EXAMPLE 1 --------------------------
PS C:\\>Example1: Remove the SecurityPolicy TestSP
PS C:\\> Get-NsxSecurityPolicy TestSP | Remove-NsxSecurityPolicy
Example2: Remove the SecurityPolicy $sp without confirmation.
PS C:\\> $sp | Remove-NsxSecurityPolicy -confirm:$false
RELATED LINKS
SYNOPSIS
Removes the specified NSX Security Policy.
SYNTAX
Remove-NsxSecurityPolicy [-SecurityPolicy] <XmlElement> [-Confirm] [-force] [-Connection <PSObject>]
[<CommonParameters>]
DESCRIPTION
An NSX Security Policy is a set of Endpoint, firewall, and network
introspection services that can be applied to a security group.
This cmdlet removes the specified Security Policy object.
PARAMETERS
-SecurityPolicy <XmlElement>
Security Policy to Remove.
Required? true
Position? 2
Default value
Accept pipeline input? true (ByValue)
Accept wildcard characters? false
-Confirm [<SwitchParameter>]
Prompt for confirmation. Specify as -confirm:$false to disable confirmation prompt
Required? false
Position? named
Default value True
Accept pipeline input? false
Accept wildcard characters? false
-force [<SwitchParameter>]
Force removal, even if the policy is in use.
Required? false
Position? named
Default value False
Accept pipeline input? false
Accept wildcard characters? false
-Connection <PSObject>
PowerNSX Connection object
Required? false
Position? named
Default value $defaultNSXConnection
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
-------------------------- EXAMPLE 1 --------------------------
PS C:\\>Example1: Remove the SecurityPolicy TestSP
PS C:\\> Get-NsxSecurityPolicy TestSP | Remove-NsxSecurityPolicy
Example2: Remove the SecurityPolicy $sp without confirmation.
PS C:\\> $sp | Remove-NsxSecurityPolicy -confirm:$false
RELATED LINKS