Trouble pulling Windows counter data

This support forum board is for support questions relating to Nagios XI, our flagship commercial network monitoring solution.
gormank
Posts: 1114
Joined: Tue Dec 02, 2014 12:00 pm

Re: Trouble pulling Windows counter data

Post by gormank »

True, but one would think that the code in the source is there for a reason...
User avatar
mcapra
Posts: 3739
Joined: Thu May 05, 2016 3:54 pm

Re: Trouble pulling Windows counter data

Post by mcapra »

Could be a safety measure to prevent mis-labeled perfdata? I recompiled NSClient++ without that line and didn't see any major issues with CheckCounter.

Probably worth raising an issue on the github if it's disruptive:
https://github.com/mickem/nscp/issues
Former Nagios employee
https://www.mcapra.com/
gormank
Posts: 1114
Joined: Tue Dec 02, 2014 12:00 pm

Re: Trouble pulling Windows counter data

Post by gormank »

Does your output using the recompiled version have the none?
User avatar
mcapra
Posts: 3739
Joined: Thu May 05, 2016 3:54 pm

Re: Trouble pulling Windows counter data

Post by mcapra »

It did not include the "none". A more time-efficient solution might be a simple sed as part of the CLI execution:

EDIT: Actually don't use sed. This discards the exit code and makes your check useless.
Former Nagios employee
https://www.mcapra.com/
gormank
Posts: 1114
Joined: Tue Dec 02, 2014 12:00 pm

Re: Trouble pulling Windows counter data

Post by gormank »

This can be closed...
Locked