What is this?

This knowledgebase contains questions and answers about PRTG Network Monitor and network monitoring in general.

Learn more

PRTG Network Monitor

Intuitive to Use. Easy to manage.
More than 500,000 users rely on Paessler PRTG every day. Find out how you can reduce cost, increase QoS and ease planning, as well.

Free Download

Top Tags


View all Tags

Windows Update Sensor to include BatchPatch

Votes:

0

In the following code block for the last windows update time, please add a check for BatchPatch as an ApplicationID. We have several Server Core machines that are only updated this way, it doesn't show a last update date. $searcher = (New-Object -ComObject Microsoft.Update.Session).CreateUpdateSearcher(); $count = $searcher.GetTotalHistoryCount(); $result = 0; if ($count -gt 0) { $index = 0; $maxindex = 100; if ($count -le 100) { $maxindex = $count; } $history = $searcher.QueryHistory($index, $maxindex); foreach ($item in $history) { $clappid = $item.ClientApplicationID if ($clappid -eq 'CcmExec' -or # SCCM Updater $clappid -eq 'UpdateOrchestrator' -or # Windows 10+ Updater $clappid -eq 'AutomaticUpdates' -or # before Windows 10 Updater $clappid -eq 'AutomaticUpdatesWuApp' # WSUS Updater ) { if ($item.ResultCode -eq 2) { # 2 = orcSucceeded $result = $([int64]$($((get-date).ToUniversalTime()) - ($searcher.QueryHistory($index, 1) | Select-Object Date).Date).TotalSeconds); break; } } $index++; } if ($result -eq 0) { $result = -3; # the last 100 entries didn't contain a successfull windows update } } else { $result = -2; # the history entry collection is empty } $result

powershell sensor windows-update-status

Created on Jan 3, 2019 10:03:54 PM



5 Replies

Votes:

0

I'll forward this thread to the sensor developer to see what's his take on this is :) Please bear with us, it may take some time until I hear from him.


PRTG Scheduler | PRTGapi | Feature Requests | WMI Issues | SNMP Issues

Kind regards,
Stephan Linke, Tech Support Team

Created on Jan 7, 2019 10:38:22 AM by  Stephan Linke [Paessler Support]



Votes:

0

This will indeed be fixed via 19.x.48, set for release at the end of January. You can download the updated Sensor executable here. Simply place it in the following directory, after backing up the original file:

C:\Program Files (x86)\PRTG Network Monitor\Sensor System

Does the sensor then work as you'd like it to work?


PRTG Scheduler | PRTGapi | Feature Requests | WMI Issues | SNMP Issues

Kind regards,
Stephan Linke, Tech Support Team

Created on Jan 7, 2019 7:38:59 PM by  Stephan Linke [Paessler Support]

Last change on Jan 7, 2019 7:39:41 PM by  Stephan Linke [Paessler Support]



Votes:

0

Yes it works great! Thank you!

Created on Jan 7, 2019 7:49:45 PM



Votes:

0

Awesome, thanks for the quick revert :) Have a good one!


PRTG Scheduler | PRTGapi | Feature Requests | WMI Issues | SNMP Issues

Kind regards,
Stephan Linke, Tech Support Team

Created on Jan 7, 2019 8:16:06 PM by  Stephan Linke [Paessler Support]



Votes:

0

I just wanted to follow up on this. With PRTG 19.1.48.2891, the sensor has been implemented natively. If not already done, I would ask you to install the update as soon as possible. In addition to the bug fixing, additional improvements have been made.

More details can be found at https://www.paessler.com/prtg/history/stable. Most of the changes can be found in version 19.1.48.2868 of February 2nd 2019.


PRTGapi | Feature Requests | WMI Issues | SNMP Issues

Kind regards,
Stephan Linke, Tech Support Team

Created on Feb 20, 2019 12:45:31 PM by  Stephan Linke [Paessler Support]




Disclaimer: The information in the Paessler Knowledge Base comes without warranty of any kind. Use at your own risk. Before applying any instructions please exercise proper system administrator housekeeping. You must make sure that a proper backup of all your data is available.