Set-CMSoftwareMeteringSetting

Configures Configuration Manager software metering properties.

Syntax

Set-CMSoftwareMeteringSetting
   [-AutoCreateDisabledRule <Boolean>]
   [-AutoCreatePercentage <Int32>]
   [-AutoCreateThreshold <Int32>]
   [-Confirm]
   [-DataRetentionDayCount <Int32>]
   [-DisableWildcardHandling]
   [-ForceWildcardHandling]
   [-WhatIf]
   [<CommonParameters>]

Description

The Set-CMSoftwareMeteringSetting cmdlet configures software metering properties for Microsoft System Center Configuration Manager.

Software metering can use software inventory information to create software metering rules. When you select this feature, System Center Configuration Manager identifies multiple computers that use the same software and creates a rule to track that usage. You decide how long to keep software metering data that System Center Configuration Manager uses to create rules.

To prevent System Center Configuration Manager from creating too many rules, you can specify what percentage of computers use a piece of software before System Center Configuration Manager creates a rule.

You can also set a rule threshold. If the number of software metering rules exceeds this threshold, System Center Configuration Manager stops automatically creating rules.

When System Center Configuration Manager creates a rule automatically, it creates that rule as disabled. A disabled rule does not collect information from clients. You can use the Enable-CMSoftwareMeteringRule cmdlet to enable a rule. You can use the Remove-CMSoftwareMeteringRule cmdlet to remove unwanted rules.

Examples

Example 1: Disable automatic rule creation

PS C:\> Set-CMSoftwareMeteringSetting -AutoCreateDisabledRule $False

This command disables automatic rule creation. System Center Configuration Manager does not automatically create software metering rules after you run this command.

Example 2: Configure automatic rule creation

PS C:\> Set-CMSoftwareMeteringSetting -AutoCreateDisabledRule $True -AutoCreatePercentage 50 -AutoCreateThreshold 200 -DataRetentionDayCount 30

This command enables automatic rule creation and sets properties for it. This command sets the percentage of computers that use a piece of software to 50 percent, the rule threshold to 200, and the amount of time System Center Configuration Manager keeps software metering data to 30 days.

Example 3: Change automatic rule creation percentage

PS C:\> Set-CMSoftwareMeteringSetting -AutoCreatePercentage 20

This command changes the percentage of computers that use a piece of software to 20 percent.

Optional Parameters

-AutoCreateDisabledRule

Specifies whether Configuration Manager automatically creates software metering rules. If this value is $True, Configuration Manager automatically creates software metering rules. If this value is $False, it does not automatically create rules.When Configuration Manager creates rules, it creates them as disabled.

You can use the values set by other parameters of this cmdlet to limit creation of rules.

Type:Boolean
Required:False
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-AutoCreatePercentage

Specifies a percentage of computers that use a piece of software for Configuration Manager to create a rule. Software metering calculates the number of computers as all the computers monitored for software metering by Configuration Manager, not just for a single site. Valid values are integers from 1 through 99.

Type:Int32
Required:False
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-AutoCreateThreshold

Specifies a number of software metering rules as a threshold. When Configuration Manager exceeds this threshold, it stops automatically creating rules. The number of rules counted for this threshold includes all software metering rules, not only those that Configuration Manager creates automatically. Valid values are integers from 1 through 1000.

Type:Int32
Required:False
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-Confirm

Prompts you for confirmation before running the cmdlet.

Type:SwitchParameter
Aliases:cf
Required:False
Position:Named
Default value:False
Accept pipeline input:False
Accept wildcard characters:False
-DataRetentionDayCount

Specifies the number of days that Configuration Manager keeps software metering data.

Type:Int32
Required:False
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-DisableWildcardHandling

Indicates that wildcard handling is disabled.

Type:SwitchParameter
Required:False
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-ForceWildcardHandling

Indicates that wildcard handling is enabled.

Type:SwitchParameter
Required:False
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-WhatIf

Shows what would happen if the cmdlet runs. The cmdlet is not run.

Type:SwitchParameter
Aliases:wi
Required:False
Position:Named
Default value:False
Accept pipeline input:False
Accept wildcard characters:False