Error while executing check command

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.
Locked
Pratapa
Posts: 144
Joined: Tue Oct 01, 2019 1:33 am

Error while executing check command

Post by Pratapa »

Hi,

When we execute the following check command we are getting following error.

[root@nagios libexec]# ./check_nrpe -H host1 -p 5666 -c CheckEventLog -a filter=new file=system MaxWarn=1 MaxCrit=1 filter-generated=\>5m filter+eventID=="10004" filter+eventType==error filter+eventSource==DCOM filter=in filter=all truncate=30
CHECK_NRPE: Receive header underflow - only 0 bytes received (4 expected).


[root@nagios]# ./check_nrpe -H host1 -p 5666
I (0.3.5.1 2008-09-24) seem to be doing fine...

[root@nagios]# ./check_nrpe -H host1
I (0.3.5.1 2008-09-24) seem to be doing fine...


I truncated the command and tried.

[root@nagios]# ./check_nrpe -H host1 -p 5666 -c CheckEventLog -a filter=new file=system
CHECK_NRPE: Receive header underflow - only 0 bytes received (4 expected).



What is wrong in the check command.

Please help me.

Regards,
Pratapa
User avatar
tgriep
Madmin
Posts: 9177
Joined: Thu Oct 30, 2014 9:02 am

Re: Error while executing check command

Post by tgriep »

The NSClient++ agent you are running is very old and I recommend upgrading to a newer version if possible.

The error is caused be a missing option in the NSClient++ ini file so can you go to the following folder

Code: Select all

C:\Program Files\NSClient++
Get the nsc.ini file and upload it here so we can view it?
Be sure to check out our Knowledgebase for helpful articles and solutions!
Pratapa
Posts: 144
Joined: Tue Oct 01, 2019 1:33 am

Re: Error while executing check command

Post by Pratapa »

I replied to the user asking for details.

I will get back to you once I get the details from the user.
Pratapa
Posts: 144
Joined: Tue Oct 01, 2019 1:33 am

Re: Error while executing check command

Post by Pratapa »

Hi,

Please find the details

NSClient++ version is NSClientpp (Nagios) 0.3.5.2 2008-09-24 w32.

Uploaded nsc.ini file
Attachments
NSC.rar
nsc.ini file
(4.57 KiB) Downloaded 129 times
User avatar
tgriep
Madmin
Posts: 9177
Joined: Thu Oct 30, 2014 9:02 am

Re: Error while executing check command

Post by tgriep »

That agent is 11 years old so I don't know if what I suggest will work.

Edit the nsc.ini file and under the [NRPE] section, change the following from

Code: Select all

;allow_arguments=0
;allow_nasty_meta_chars=0
to

Code: Select all

allow_arguments=1
allow_nasty_meta_chars=1
Save the change and restart NSClient++ and test the command.
Be sure to check out our Knowledgebase for helpful articles and solutions!
Locked