New-CMOperatingSystemImageUpdateSchedule

Creates an operating system image update schedule.

Syntax

New-CMOperatingSystemImageUpdateSchedule
   [-ContinueOnError <Boolean>]
   [-CustomSchedule <DateTime>]
   -InputObject <IResultObject>
   -SoftwareUpdate <IResultObject[]>
   [-UpdateDistributionPoint <Boolean>]
   [-Utc <Boolean>]
   [-DisableWildcardHandling]
   [-ForceWildcardHandling]
   [-WhatIf]
   [-Confirm]
   [<CommonParameters>]
New-CMOperatingSystemImageUpdateSchedule
   [-ContinueOnError <Boolean>]
   [-CustomSchedule <DateTime>]
   -SoftwareUpdate <IResultObject[]>
   [-UpdateDistributionPoint <Boolean>]
   [-Utc <Boolean>]
   [-DisableWildcardHandling]
   [-ForceWildcardHandling]
   [-WhatIf]
   [-Confirm]
   [<CommonParameters>]
New-CMOperatingSystemImageUpdateSchedule
   [-ContinueOnError <Boolean>]
   [-CustomSchedule <DateTime>]
   -SoftwareUpdate <IResultObject[]>
   [-UpdateDistributionPoint <Boolean>]
   [-Utc <Boolean>]
   [-DisableWildcardHandling]
   [-ForceWildcardHandling]
   [-WhatIf]
   [-Confirm]
   [<CommonParameters>]
New-CMOperatingSystemImageUpdateSchedule
   [-ContinueOnError <Boolean>]
   [-CustomSchedule <DateTime>]
   -SoftwareUpdate <IResultObject[]>
   [-UpdateDistributionPoint <Boolean>]
   [-Utc <Boolean>]
   [-DisableWildcardHandling]
   [-ForceWildcardHandling]
   [-WhatIf]
   [-Confirm]
   [<CommonParameters>]
New-CMOperatingSystemImageUpdateSchedule
   -Id <String>
   [-ContinueOnError <Boolean>]
   [-RunNow]
   -SoftwareUpdate <IResultObject[]>
   [-UpdateDistributionPoint <Boolean>]
   [-DisableWildcardHandling]
   [-ForceWildcardHandling]
   [-WhatIf]
   [-Confirm]
   [<CommonParameters>]
New-CMOperatingSystemImageUpdateSchedule
   [-ContinueOnError <Boolean>]
   -InputObject <IResultObject>
   [-RunNow]
   -SoftwareUpdate <IResultObject[]>
   [-UpdateDistributionPoint <Boolean>]
   [-DisableWildcardHandling]
   [-ForceWildcardHandling]
   [-WhatIf]
   [-Confirm]
   [<CommonParameters>]
New-CMOperatingSystemImageUpdateSchedule
   -Name <String>
   [-ContinueOnError <Boolean>]
   [-RunNow]
   -SoftwareUpdate <IResultObject[]>
   [-UpdateDistributionPoint <Boolean>]
   [-DisableWildcardHandling]
   [-ForceWildcardHandling]
   [-WhatIf]
   [-Confirm]
   [<CommonParameters>]
New-CMOperatingSystemImageUpdateSchedule
   [-ContinueOnError <Boolean>]
   [-RunNow]
   -SoftwareUpdate <IResultObject[]>
   [-UpdateDistributionPoint <Boolean>]
   [-DisableWildcardHandling]
   [-ForceWildcardHandling]
   [-WhatIf]
   [-Confirm]
   [<CommonParameters>]

Description

The New-CMOperatingSystemImageUpdateSchedule cmdlet creates an operating system image update schedule.

Examples

Example 1: Create an operating system image update schedule

PS ABC:\> $Win10Image = Get-CMOperatingSystemImage -Name "Windows 10 Enterprise"
PS ABC:\> $Win10SU = Get-CMSoftwareUpdate -UpdateGroupName "Win10SUgroup01"
PS ABC:\> New-CMOperatingSystemImageUpdateSchedule -Name $Win10Image.Name -SoftwareUpdate $Win10SU -RunNow -ContinueOnError $True

The first command gets the operating system image object named Windows 10 Enterprise and stores the object in the $Win10Image variable.

The second command gets the software update object for the update group named Win10SUgroup01 and stores the object in the $Win10SU variable.

The last command creates an operating system image update schedule to update the operating system image named Windows 10 Enterprise with the update stored in $Win10SU. The update will run now, and will continue to apply the updates even if an error is encountered.

Required Parameters

-Id

Specifies the ID of an operating system image.

Type:String
Aliases:PackageId
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-InputObject

Specifies an operating system image object. To obtain an operating system image object, use the Get-CMOperatingSystemImage cmdlet.

Type:IResultObject
Position:Named
Default value:None
Accept pipeline input:True (ByValue)
Accept wildcard characters:False
-Name

Specifies the name of an operating system image.

Type:String
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-SoftwareUpdate

Specifies an array of software update objects. To obtain a software update object, use the Get-CMSoftwareUpdate cmdlet.

Type:IResultObject[]
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False

Optional Parameters

-Confirm

Prompts you for confirmation before running the cmdlet.

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

Indicates whether software updates should be applied to the image even when there is an error.

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

Specifies the date and time when the software updates are applied to the operating system image.

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

DisableWildcardHandling treats wildcard characters as literal character values. Cannot be combined with ForceWildcardHandling.

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

ForceWildcardHandling processes wildcard characters and may lead to unexpected behavior (not recommended). Cannot be combined with DisableWildcardHandling.

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

Indicates that the update should run now.

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

Indicates whether the operating system image on distribution points is updated after the software updates are applied.

Type:Boolean
Aliases:UpdateDistributionPointsWithImage, UpdateDistributionPoints
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-Utc

Indicates whether to use UTC time.

Type:Boolean
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
Position:Named
Default value:False
Accept pipeline input:False
Accept wildcard characters:False