I have WSUS installed on a Server 2012R2 box. I am trying to use the Get-WsusComputer powershell command to get a list of computers with pending or failed updates. The documentation for the command seems to suggest that -ComputerUpdateStatus
is the correct option for this.
-ComputerUpdateStatus Specifies the computer update state as represented in the WSUS Console user interface. The acceptable values for this parameter are: ...
The problem I am having is that using this option doesn't seem to make any difference. When I look at the console in the GUI about 75% of my systems are in the OK state, a few have been offline for a while, a few have failures, and the rest show a couple 1-2 updates in the needed column.
PS D:\> get-wsuscomputer -ComputerTargetGroups Workstations | Measure-Object
Count : 264
PS D:\> get-wsuscomputer -ComputerTargetGroups Workstations `
>> -ComputerUpdateStatus Failed | Measure-Object
Count : 264
PS D:\> get-wsuscomputer -ComputerTargetGroups Workstations `
>> -ComputerUpdateStatus FailedOrNeeded | Measure-Object
Count : 264
Is this option simply broken? Or am I missing something obvious about how to use it?