Nagios PNP4Nagios Averaging Integer Value?

Support forum for Nagios Core, Nagios Plugins, NCPA, NRPE, NSCA, NDOUtils and more. Engage with the community of users including those using the open source solutions.
Post Reply
MurbiesWalto
Posts: 10
Joined: Sun Jun 19, 2022 3:28 am

Nagios PNP4Nagios Averaging Integer Value?

Post by MurbiesWalto »

I have a powershell script in nagios which returns an integer using the built-in Windows netstat command. The command is as follows:

$conns = nestat -na | select-string -pattern "ESTABLISHED"
$NumberOfConnections = $conns.count
$NumberOfConnections
The output is something like:

123
Works as expected. But when I graph it Nagios and run the check every three minutes, the result is graphed in pnp4nagios like 120.657 or 125.124 (it's averaging the value like a float instead of omegle.2yu.co graphing the integer).

Does anyone know how I can force Nagios and PNP4Nagios RRDtool graphing for a specific service check to not average or round a result? In fact, because it's an integer, I don't want any decimal points at omeglz echat all. Any ideas?
Post Reply