Set-WsusDynamicCategory

Sets the synchronization status of a dynamic category.

Syntax

Set-WsusDynamicCategory
   [-UpdateServer <IUpdateServer>]
   -Name <String>
   -DynamicCategoryType <DynamicCategoryType>
   -Status <WsusDynamicCategoryStatus>
   [-WhatIf]
   [-Confirm]
   [<CommonParameters>]
Set-WsusDynamicCategory
   [-UpdateServer <IUpdateServer>]
   [-Status <WsusDynamicCategoryStatus>]
   -InputObject <IDynamicCategory>
   [-WhatIf]
   [-Confirm]
   [<CommonParameters>]

Description

The Set-WsusDynamicCategory cmdlet sets the synchronization status of a dynamic category in a specified Windows Server Update Services (WSUS) server.

Examples

Example 1: Set the synchronization status of a dynamic category

PS C:\> Get-WsusDynamicCategory -DynamicCategoryType Device -Name "PCI/Device07" | Set-WsusDynamicCategory -Status Blocked

This command gets a dynamic category from the local server by using the Get-WsusDynamicCategory cmdlet. The command passes the dynamic category to the current cmdlet by using the pipeline operator. The current cmdlet sets the synchronization status to Blocked. This value means that no updates are synchronized for this dynamic category.

Parameters

-Confirm

Prompts you for confirmation before running the cmdlet.

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

-DynamicCategoryType

Specifies the type of the dynamic category that this cmdlet modifies. The acceptable values for this parameter are:

  • ComputerModel
  • Device
  • Application
Type:DynamicCategoryType
Aliases:Type
Accepted values:ComputerModel, Device, Application, Any
Position:Named
Default value:None
Required:True
Accept pipeline input:False
Accept wildcard characters:False

-InputObject

Specifies a dynamic category object. This cmdlet modifies the synchronization settings for the dynamic category that this parameter specifies. To obtain a dynamic category, use the Get-WsusDynamicCategory cmdlet.

Type:IDynamicCategory
Position:Named
Default value:None
Required:True
Accept pipeline input:True
Accept wildcard characters:False

-Name

Specifies the name of the dynamic category to modify.

Type:String
Position:Named
Default value:None
Required:True
Accept pipeline input:False
Accept wildcard characters:False

-Status

Specifies the update synchronization status for the dynamic category. The acceptable values for this parameter are:

  • Blocked. No updates are being synchronized for this dynamic category.
  • SyncUpdates. Updates are being synchronized for this dynamic category.
Type:WsusDynamicCategoryStatus
Accepted values:Blocked, InventoryOnly, SyncUpdates, Blocked, InventoryOnly, SyncUpdates
Position:Named
Default value:None
Required:True
Accept pipeline input:False
Accept wildcard characters:False

-UpdateServer

Specifies a WSUS server. This cmdlet modifies a dynamic category on the server that this parameter specifies. To obtain a server, use the Get-WsusServer cmdlet. If you do not specify a value for this parameter, the cmdlet modifies dynamic categories on the local server.

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

Inputs

IDynamicCategory

Outputs

None