Edit

Share via


Set-CMSoftwareUpdate

Sets a software update.

Syntax

SetById (Default)

Set-CMSoftwareUpdate
    -Id <String>
    [-CustomSeverity <CustomSeverityType>]
    [-MaximumExecutionMins <Int32>]
    [-DisableWildcardHandling]
    [-ForceWildcardHandling]
    [-WhatIf]
    [-Confirm]
    [<CommonParameters>]

SetByName

Set-CMSoftwareUpdate
    -Name <String>
    [-CustomSeverity <CustomSeverityType>]
    [-MaximumExecutionMins <Int32>]
    [-DisableWildcardHandling]
    [-ForceWildcardHandling]
    [-WhatIf]
    [-Confirm]
    [<CommonParameters>]

SetByValue

Set-CMSoftwareUpdate
    -InputObject <IResultObject>
    [-CustomSeverity <CustomSeverityType>]
    [-MaximumExecutionMins <Int32>]
    [-DisableWildcardHandling]
    [-ForceWildcardHandling]
    [-WhatIf]
    [-Confirm]
    [<CommonParameters>]

Description

The Set-CMSoftwareUpdate cmdlet changes configuration settings for a software update. You can use this cmdlet to set the severity and the maximum run time for an update. A software update is an update to Windows or other software that Configuration Manager applies to a collection of computers.

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 software update and change its settings

PS XYZ:\> Get-CMSoftwareUpdate -Name "Update for Windows 10 (KB3106932)" | Set-CMSoftwareUpdate -MaximumExecutionMins 10 -CustomSeverity Critical

This command gets the software update object named Update for Windows 10 (KB3106932) and uses the pipeline operator to pass the object to Set-CMSoftwareUpdate, which sets the severity of the update to Critical and the maximum installation time to 10 minutes.

Example 2: Modify software update settings

PS XYZ:\> Set-CMSoftwareUpdate -Id 16777979 -MaximumExecutionMins 10 -CustomSeverity Critical

This command gets the software update with the ID of 16777979 and sets the severity of the update to Critical and the maximum installation time to 10 minutes.

Parameters

-Confirm

Prompts you for confirmation before running the cmdlet.

Parameter properties

Type:SwitchParameter
Default value:False
Supports wildcards:False
DontShow:False
Aliases:cf

Parameter sets

(All)
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-CustomSeverity

Specifies the severity for the software update. Valid values are:

  • Critical
  • Important
  • Low
  • Moderate
  • None

Parameter properties

Type:CustomSeverityType
Default value:None
Accepted values:None, Low, Moderate, Important, Critical
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

-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

-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 ID of software updates.

Parameter properties

Type:String
Default value:None
Supports wildcards:False
DontShow:False
Aliases:CIId, CI_ID

Parameter sets

SetById
Position:Named
Mandatory:True
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-InputObject

Specifies a software update object. To obtain a software update object, use the Get-CMSoftwareUpdate cmdlet.

Parameter properties

Type:IResultObject
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

SetByValue
Position:Named
Mandatory:True
Value from pipeline:True
Value from pipeline by property name:False
Value from remaining arguments:False

-MaximumExecutionMins

Specifies, in minutes, the maximum amount of time that a software update has to complete installation on client computers.

Parameter properties

Type:Int32
Default value:None
Supports wildcards:False
DontShow:False
Aliases:MaximumExecutionMinutes

Parameter sets

(All)
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-Name

Specifies the name of a software update.

Parameter properties

Type:String
Default value:None
Supports wildcards:False
DontShow:False
Aliases:LocalizedDisplayName

Parameter sets

SetByName
Position:Named
Mandatory:True
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-WhatIf

Shows what would happen if the cmdlet runs. The cmdlet doesn't run.

Parameter properties

Type:SwitchParameter
Default value:False
Supports wildcards:False
DontShow:False
Aliases:wi

Parameter sets

(All)
Position:Named
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.

Inputs

Microsoft.ConfigurationManagement.ManagementProvider.IResultObject

Outputs

System.Object