So, I'm required to provide reports on how "fast" we are handling incidents within PRTG, i.e. present the timings between a sensor going down and being acknowledged. Unfortunately, I can't find anything in the reports. Can you guys help?


Article Comments

This can be done using the following tool: https://gist.github.com/stephanlinke/e38c9cee2826a24e580cb0998c684d54

It will provide you with a list of incidents for each sensor and how long it took for them to being acknowledged. Note that it requires PrtgAPI to be installed on the host you're executing it.

The output will look somewhat like this:

DateObjidDeviceSensorMessageResponse Time
09.10.2018 15:06:221002ProbeProbe HealthDown4d 1h 26s

You need to configure the PRTG Server as well as the start/end date (default: last 14 days). The amount of days depend on the historic data purging for the log entries (default is 30 days). Make sure to configure that properly under

Setup | System Administration | Core & Probes | Historic Data Purging | Logfile Records

Note that you'll get one entry per sensor state change, so it might turn out to be a long list. Put the following at the end of the script to receive CSV based output:

$Incidents | ConvertTo-CSV | Out-File C:\temp\outages.csv

Note that C:\temp needs to exist for this to work :)


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

Kind regards,
Stephan Linke, Tech Support Team


Oct, 2018 - Permalink