Get-CMConfigurationPolicy
Gets a configuration policy.
Syntax
SearchByName (Default)
Get-CMConfigurationPolicy
[[-Name] <String>]
[-AsXml]
[-CategoryInstanceType <String[]>]
[-Fast]
[-DisableWildcardHandling]
[-ForceWildcardHandling]
[<CommonParameters>]
SearchById
Get-CMConfigurationPolicy
[-Id] <Int32>
[-AsXml]
[-CategoryInstanceType <String[]>]
[-Fast]
[-DisableWildcardHandling]
[-ForceWildcardHandling]
[<CommonParameters>]
SearchByValue
Get-CMConfigurationPolicy
[[-InputObject] <IResultObject>]
[-AsXml]
[-CategoryInstanceType <String[]>]
[-Fast]
[-DisableWildcardHandling]
[-ForceWildcardHandling]
[<CommonParameters>]
Description
The Get-CMConfigurationPolicy cmdlet gets a configuration policy.
Note
Run Configuration Manager cmdlets from the Configuration Manager site drive, for example PS XYZ:\>
. For more information, see getting started.
Examples
Example 1: Get a configuration policy by name
PS XYZ:\> Get-CMConfigurationPolicy -Name "TrustedCACert01" -AsXml
This command gets the configuration policy named TrustedCACert01 and displays the output in XML format.
Example 2: Get a configuration policy by ID
PS XYZ:\> Get-CMConfigurationPolicy -Id 16777454 -Fast
This command gets the configuration policy with the ID of 16777454 and does not display lazy properties.
Parameters
-AsXml
Specifies that the configuration policy is returned in XML format.
Parameter properties
Type: | SwitchParameter |
Default value: | None |
Supports wildcards: | False |
DontShow: | False |
Parameter sets
(All)
Position: | Named |
Mandatory: | False |
Value from pipeline: | False |
Value from pipeline by property name: | False |
Value from remaining arguments: | False |
-CategoryInstanceType
Specifies an array of category instance types.
Parameter properties
Type: | String[] |
Default value: | None |
Supports wildcards: | False |
DontShow: | False |
Aliases: | CategoryInstanceTypes |
Parameter sets
(All)
Position: | Named |
Mandatory: | False |
Value from pipeline: | False |
Value from pipeline by property name: | False |
Value from remaining arguments: | False |
-DisableWildcardHandling
This parameter treats wildcard characters as literal character values. You can't combine it with ForceWildcardHandling.
Parameter properties
Type: | SwitchParameter |
Default value: | None |
Supports wildcards: | False |
DontShow: | False |
Parameter sets
(All)
Position: | Named |
Mandatory: | False |
Value from pipeline: | False |
Value from pipeline by property name: | False |
Value from remaining arguments: | False |
-Fast
Indicates that the cmdlet does not automatically refresh lazy properties.
Lazy properties contain values that are relatively inefficient to retrieve which can cause additional network traffic and decrease cmdlet performance. If lazy properties are not used, this parameter should be specified.
Parameter properties
Type: | SwitchParameter |
Default value: | None |
Supports wildcards: | False |
DontShow: | False |
Parameter sets
(All)
Position: | Named |
Mandatory: | False |
Value from pipeline: | False |
Value from pipeline by property name: | False |
Value from remaining arguments: | False |
-ForceWildcardHandling
This parameter processes wildcard characters and may lead to unexpected behavior (not recommended). You can't combine it with DisableWildcardHandling.
Parameter properties
Type: | SwitchParameter |
Default value: | None |
Supports wildcards: | False |
DontShow: | False |
Parameter sets
(All)
Position: | Named |
Mandatory: | False |
Value from pipeline: | False |
Value from pipeline by property name: | False |
Value from remaining arguments: | False |
-Id
Specifies the CI__ID of a configuration policy.
Parameter properties
Type: | Int32 |
Default value: | None |
Supports wildcards: | False |
DontShow: | False |
Aliases: | CIId, CI_ID |
Parameter sets
SearchById
Position: | 0 |
Mandatory: | True |
Value from pipeline: | False |
Value from pipeline by property name: | False |
Value from remaining arguments: | False |
-InputObject
Specifies a configuration policy object.
Parameter properties
Type: | IResultObject |
Default value: | None |
Supports wildcards: | False |
DontShow: | False |
Parameter sets
SearchByValue
Position: | 0 |
Mandatory: | False |
Value from pipeline: | True |
Value from pipeline by property name: | False |
Value from remaining arguments: | False |
-Name
Specifies the name of a configuration policy.
Parameter properties
Type: | String |
Default value: | None |
Supports wildcards: | True |
DontShow: | False |
Aliases: | LocalizedDisplayName |
Parameter sets
SearchByName
Position: | 0 |
Mandatory: | False |
Value from pipeline: | False |
Value from pipeline by property name: | False |
Value from remaining arguments: | False |
CommonParameters
This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutBuffer, -OutVariable, -PipelineVariable, -ProgressAction, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters.