The System Center Configuration Manager Cmdlet Library
Microsoft updates PowerShell cmdlets for Configuration Manager on a regular basis. These updates are not necessarily related to other Configuration Manager updates and releases. To make sure that you have the most recent updates, we recommend you replace your cmdlet library with the new System Center Configuration Manager Cmdlet Library available on the Download Center. The System Center Configuration Manager Cmdlet Library checks for library updates on a daily basis, and notifies you to download the updated library.
Note
This cmdlet library requires PowerShell 3.0 or later. When the update check is made by cmdlets, execution will be blocked until the check completes or times out. To understand the behavior of the update feature, see the default settings described in the Configuration section in this topic.
Tip
General and reference information about the Configuration Manager PowerShell cmdlets is available in the Configuration Manager PowerShell documentation. To learn more about PowerShell, see Using Windows PowerShell.
The System Center Configuration Manager Cmdlet Library supports the following versions of System Center Configuration Manager:
System Center 2012 Configuration Manager SP2
System Center 2012 Configuration Manager R2
System Center 2012 Configuration Manager R2 SP1
The following must be installed on the workstation computer on which the System Center Configuration Manager Cmdlet Library will be installed:
An operating system compatible with System Center Configuration Manager. For a list of compatible operating systems, see Supported Configurations for Configuration Manager.
A supported version of the Configuration Manager console.
Download ConfigMgr2012PowerShellCmdlets.msi from the Microsoft Download Center.
Follow the instructions in the setup wizard to install the System Center Configuration Manager Cmdlet Library.
After the installation you can use the cmdlets in the library.
The System Center Configuration Manager Cmdlet Library includes these cmdlets to enable the update notification functionality:
Get-CMCmdletUpdateCheck gets the update feature configuration and will indicate if user policy is being overridden by system policy.
Send-CMCmdletUpdateCheck lets you perform an unscheduled update check. An unscheduled check does not consider policy settings.
Set-CMCmdletUpdateCheck configures the update check settings on a per-user or per-system basis. You must be running as an administrator to set system settings.
Setting name | Description | Behavior |
---|---|---|
UpdateCheckIsEnabled |
0 = disabled 1 = enabled |
Enabled by default. If set to 0, supersedes the other settings described here. |
UpdateCheckTimeoutSeconds |
Seconds until check times out |
The check times out in 60 seconds by default if there is no response from the Microsoft Download Center. Whichever value (user or system) is shortest is applied. |
UpdateCheckIntervalMinutes |
Minutes until next update check will occur |
Default is a full day. Whichever value (user or system) is longest is applied. |
UpdateCheckIsEnabledOnCmdletStart |
0 = disable 1 = enabled |
Disabled by default. When enabled, an update check occurs when a cmdlet runs if past the update check interval. |
UpdateCheckIsEnabledFromCMDrive |
0 = disable 1 = enabled |
Enabled by default. When enabled, an update check occurs when a new connection is made to a site if past the update check interval. |
Note
An elevated PowerShell session must be used if using -System to configure system-wide policy. If you disable the update check for the system, it will be disabled for all users.
You can configure the update feature through group policy using these registry keys:
User registry key: HKCU\Software\Microsoft\ConfigMgr10\PowerShell
System registry key: HKLM\Software\Microsoft\ConfigMgr10\PowerShell
For example, you can disable UpdateCheckisEnabled with reg add HKLM\Software\Microsoft\ConfigMgr10\PowerShell /v UpdateCheckIsEnabled /t REG_DWORD /d 0.
Get-CMCmdletUpdate –CurrentUser returns the Resultant Set of Policy and will tell you whether system policy is overriding user policy. Get-CMCmdletUpdate –System will tell you what is being overridden by system policy.
Uninstalling the System Center Configuration Manager Cmdlet Library removes all of the cmdlets from the System Center 2012 Configuration Manager administrator console. The originally installed cmdlets will not be restored automatically. To restore the original set of cmdlets, you must repair or reinstall the System Center 2012 Configuration Manager administrator console.