Export (0) Print
Expand All

Get-WsusUpdate

Get-WsusUpdate

Gets the WSUS update object with details about the update.

Syntax

Parameter Set: ID
Get-WsusUpdate -UpdateId <Guid> [-InformationAction <System.Management.Automation.ActionPreference> {SilentlyContinue | Stop | Continue | Inquire | Ignore | Suspend} ] [-InformationVariable <System.String> ] [-RevisionNumber <Int32> ] [-UpdateServer <IUpdateServer> ] [ <CommonParameters>]

Parameter Set: Scoped
Get-WsusUpdate [-Approval <WsusApprovedState> {Approved | Unapproved | AnyExceptDeclined | Declined} ] [-Classification <WsusUpdateClassifications> {All | Critical | Security | WSUS} ] [-InformationAction <System.Management.Automation.ActionPreference> {SilentlyContinue | Stop | Continue | Inquire | Ignore | Suspend} ] [-InformationVariable <System.String> ] [-Status <WsusUpdateInstallationState> {NoStatus | InstalledOrNotApplicable | InstalledOrNotApplicableOrNoStatus | Failed | Needed | FailedOrNeeded | Any} ] [-UpdateServer <IUpdateServer> ] [ <CommonParameters>]




Detailed Description

The Get-WsusUpdate cmdlet gets the Windows Server Update Services (WSUS) update object with details about the update. This cmdlet requires the update unique identifier (GUID) or a set of filter criteria such as classification, approval and status as parameter.

The Get-WsusUpdate cmdlet can be called in two ways:

-- Passing in the Update ID (GUID) and RevisionNumber. This cmdlet returns a single update matching the specified Update ID and revision number.
-- Passing in filter parameters. These parameters include Classification, Approval, and Status. One or more updates matching the specified criteria are returned.

Parameters

-Approval<WsusApprovedState>

Specifies the approved state of the one or more updates to be returned. The acceptable values for this parameter are: 

-- Unapproved
-- Declined
-- Approved
-- AnyExceptDeclined


Aliases

none

Required?

false

Position?

named

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-Classification<WsusUpdateClassifications>

Specifies the classification of updates for which you want to get updates. The acceptable values for this parameter are: 

-- All
-- Critical
-- Security
-- WSUS


Aliases

none

Required?

false

Position?

named

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-InformationAction<System.Management.Automation.ActionPreference>

Specifies how this cmdlet responds to an information event. The acceptable values for this parameter are: 

-- Continue
-- Ignore
-- Inquire
-- SilentlyContinue
-- Stop
-- Suspend


Aliases

infa

Required?

false

Position?

named

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-InformationVariable<System.String>

Specifies an information variable.


Aliases

iv

Required?

false

Position?

named

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-RevisionNumber<Int32>

Specifies the revision number of a specific revision of an update. To specify the latest revision, set to zero.


Aliases

none

Required?

false

Position?

named

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-Status<WsusUpdateInstallationState>

Specifies the installation status for which to search. An update will be included only if it has at least one computer with the specified status. The acceptable values for this parameter are: 

-- Needed
-- FailedOrNeeded
-- InstalledNotApplicableOrNoStatus
-- Failed
-- InstalledNotApplicable
-- NoStatus
-- Any


Aliases

none

Required?

false

Position?

named

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-UpdateId<Guid>

Specifies the update by its GUID. The GUID uniquely identifies the Group Policy Object (GPO).


Aliases

none

Required?

true

Position?

named

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-UpdateServer<IUpdateServer>

Specifies the object that contains the WSUS server. This value is obtained by calling the Get-WsusServer cmdlet and passing the resulting IUpdateServer object into this cmdlet.


Aliases

none

Required?

false

Position?

named

Default Value

none

Accept Pipeline Input?

true (ByValue)

Accept Wildcard Characters?

false

<CommonParameters>

This cmdlet supports the common parameters: -Verbose, -Debug, -ErrorAction, -ErrorVariable, -OutBuffer, and -OutVariable. For more information, see    about_CommonParameters (http://go.microsoft.com/fwlink/p/?LinkID=113216).

Inputs

The input type is the type of the objects that you can pipe to the cmdlet.

  • None

Outputs

The output type is the type of the objects that the cmdlet emits.

  • Microsoft.UpdateServices.Commands.WsusUpdate

Examples

Example 1: Get updates by status

This command gets all unapproved updates with a status of failed or needed.


PS C:\> Get-WsusUpdate -Classification All -Approval Unapproved -Status FailedOrNeeded

Example 2: Get critical unapproved updates

This command gets all critical unapproved updates.


PS C:\> Get-WsusUpdate -Classification Critical -Approval Unapproved -Status Any

Related topics

Was this page helpful?
(1500 characters remaining)
Thank you for your feedback
Show:
© 2015 Microsoft