check_nrpe changes ouput data after | token

This support forum board is for support questions relating to Nagios XI, our flagship commercial network monitoring solution.
Locked
Dietervdb
Posts: 1
Joined: Fri Mar 15, 2019 4:14 am

check_nrpe changes ouput data after | token

Post by Dietervdb »

Hi All,

I have a Powershell script on a client that is being triggerd by check_nrpe (version 3.2.1) from our Nagios server.
To do this we us on the client nsclient++ (version 0.5.2035).
Because I want to use performance data, I use the | token in the output of the Powershell script.

The code is for example:

echo "test | test"
exit 0

This produces the expected output:

PS C:\Program Files\NSClient++\scripts> .\test.ps1
test | test

But check_nrpe transforms everything ater the | token:

/usr/local/nagios/libexec/check_nrpe -H testhost-t 60 -c check_test
test |'test'=0

By this, I am unable to work with performance data in Nagios.
I already set 'allow nasty characters' to 'true', but no difference.

Do you guys have any idea what causes this problem?

Thanks,
Dieter
scottwilkerson
DevOps Engineer
Posts: 19396
Joined: Tue Nov 15, 2011 3:11 pm
Location: Nagios Enterprises
Contact:

Re: check_nrpe changes ouput data after | token

Post by scottwilkerson »

Performance data needs to have a specific format

See:
https://nagios-plugins.org/doc/guidelines.html#AEN200
Former Nagios employee
Creator:
Human Design Website
Get Your Human Design Chart
Locked