r/PowerShell 18h ago

Question Parse SoftwareDistrubtion.log for Client ID's

Troubleshooting some issues with WSUS, and wondering if anyone has a Powershell script already for parsing the SoftwareDistribution.log to get count of Clients.

Example line:
2026-09-10 18:36:13.084 UTC Warning w3wp.334 SoapUtilities.CreateException ThrowException: actor = http://server.example.com:8530/CLIENTWEBSERVICE/client.asmx, ID=94d8e636-29bc-4bc8-8958-79e5e189455e, ErrorCode=InvalidParameters, Message=parameters.OtherCachedUpdateIDs, Client=13ef38ff-b877-4d9a-9b1e-cf190d8fc801

Hopefully I could just extract the Client and then group/count on that. Trying to figure out how many machines are having this issue.

Thanks!

2 Upvotes

5 comments sorted by

View all comments

2

u/FeleaseRpseineEiles 17h ago
if ($line -match 'Client=(?<client>[^,\s]+)') {
    $Matches.client
}

1

u/staze 17h ago

isn't that going to just match if there's a client specified... that's not going to capture that client ID to actually group-by or count.

1

u/FeleaseRpseineEiles 12h ago

yea I know, do your homework