This support forum board is for support questions relating to
Nagios XI , our flagship commercial network monitoring solution.
rajasegar
Posts: 1018 Joined: Sun Mar 30, 2014 10:49 pm
Post
by rajasegar » Fri May 08, 2020 2:12 am
Old thread
https://support.nagios.com/forum/viewto ... 16&t=53665
There is a new issue now.
I have a server where there is drive C & E. Individual checks works fine
Code: Select all
[nagios@nagiosprodxi1 services]$ /usr/local/nagios/libexec/check_nrpe -u -t 60 -H 10.104.19.120 -p 5666 -c check_drivesize -a
warn=used>=70' 'crit=used>=85' 'drive=C' OK All 1 drive(s) are ok|'C: used'=94.68646GB;105.00068;127.50082;0;150.00097 'C: used %'=63%;70;85;0;100
[nagios@nagiosprodxi1 services]$ /usr/local/nagios/libexec/check_nrpe -u -t 60 -H 10.104.19.120 -p 5666 -c check_drivesize -a 'warn=used>=70' 'crit=used>=85' 'drive=D'
Filter processing failed: Failed to get size for D:: 3: The system cannot find the path specified.
: 0 >= convert(0)
[nagios@nagiosprodxi1 services]$ /usr/local/nagios/libexec/check_nrpe -u -t 60 -H 10.104.19.120 -p 5666 -c check_drivesize -a 'warn=used>=70' 'crit=used>=85' 'drive=E'
OK All 1 drive(s) are ok|'E: used'=66.88811GB;155.30634;188.58627;0;221.8662 'E: used %'=30%;70;85;0;100
However if I use drive =* it bombs
Code: Select all
[nagios@nagiosprodxi1 services]$ /usr/local/nagios/libexec/check_nrpe -u -t 60 -H 10.104.19.120 -p 5666 -c check_drivesize -a 'warn=used>=70' 'crit=used>=85' 'drive=*' "filter=drive_or_id not like 'Volume' and type not in ('CDROM', 'REMOVABLE')"
CHECK_NRPE: Invalid packet type received from server.
Is there a way to get this to work? I think it is checking drive D and exits with error.
5 x Nagios 5.6.9 Enterprise Edition
RHEL 6 & 7
rrdcached & ramdisk optimisation
ssax
Dreams In Code
Posts: 7682 Joined: Wed Feb 11, 2015 12:54 pm
Post
by ssax » Fri May 08, 2020 11:42 am
If you restart the nsclient service, does it fix it?
Please enable trace logging in your
nsclient.ini , make the check fail again, and then attach (or PM) your
nsclient.log for us to review.
Code: Select all
; LOG SECTION - Configure log properties.
[/settings/log]
; DATEMASK - The size of the buffer to use when getting messages this affects the speed and maximum size of messages you can recieve.
date format = %Y-%m-%d %H:%M:%S
; LOG LEVEL - Log level to use. Available levels are error,warning,info,debug,trace
level = trace
; FILENAME - The file to write log data to. Set this to none to disable log to file.
file name = ${exe-path}/nsclient.log
Thank you
rajasegar
Posts: 1018 Joined: Sun Mar 30, 2014 10:49 pm
Post
by rajasegar » Tue May 12, 2020 1:48 am
ssax wrote: If you restart the nsclient service, does it fix it?
Please enable trace logging in your
nsclient.ini , make the check fail again, and then attach (or PM) your
nsclient.log for us to review.
Code: Select all
; LOG SECTION - Configure log properties.
[/settings/log]
; DATEMASK - The size of the buffer to use when getting messages this affects the speed and maximum size of messages you can recieve.
date format = %Y-%m-%d %H:%M:%S
; LOG LEVEL - Log level to use. Available levels are error,warning,info,debug,trace
level = trace
; FILENAME - The file to write log data to. Set this to none to disable log to file.
file name = ${exe-path}/nsclient.log
Thank you
Restart no luck. Trace attached but I dont see any useful info in there
nsclient.log
You do not have the required permissions to view the files attached to this post.
5 x Nagios 5.6.9 Enterprise Edition
RHEL 6 & 7
rrdcached & ramdisk optimisation
ssax
Dreams In Code
Posts: 7682 Joined: Wed Feb 11, 2015 12:54 pm
Post
by ssax » Tue May 12, 2020 10:43 am
Does it work if you don't use the filter?
Code: Select all
/usr/local/nagios/libexec/check_nrpe -u -t 60 -H 10.104.19.120 -p 5666 -c check_drivesize -a 'warn=used>=70' 'crit=used>=85' 'drive=*'
rajasegar
Posts: 1018 Joined: Sun Mar 30, 2014 10:49 pm
Post
by rajasegar » Tue May 12, 2020 8:19 pm
ssax wrote: Does it work if you don't use the filter?
Code: Select all
/usr/local/nagios/libexec/check_nrpe -u -t 60 -H 10.104.19.120 -p 5666 -c check_drivesize -a 'warn=used>=70' 'crit=used>=85' 'drive=*'
Still does not work
Code: Select all
[nagios@nagiosprodxi1 ~]$ /usr/local/nagios/libexec/check_nrpe -u -t 60 -H 10.104.19.120 -p 5666 -c check_drivesize -a 'warn=used>=70' 'crit=used>=85' 'drive=*'
CHECK_NRPE: Invalid packet type received from server.
5 x Nagios 5.6.9 Enterprise Edition
RHEL 6 & 7
rrdcached & ramdisk optimisation
ssax
Dreams In Code
Posts: 7682 Joined: Wed Feb 11, 2015 12:54 pm
Post
by ssax » Wed May 13, 2020 9:38 am
I tested on mine with the latest and it's working properly.
Was this a drive that was removed while the system was running? Maybe it still sees it but can't get the statistics on it.
Does it work if you do this?
Code: Select all
/usr/local/nagios/libexec/check_nrpe -u -t 60 -H 10.104.19.120 -P 8192 -p 5666 -c check_drivesize -a 'warn=used>=70' 'crit=used>=85'
Can you try upgrading to the latest on the system and test again?
https://nsclient.org/download/
rajasegar
Posts: 1018 Joined: Sun Mar 30, 2014 10:49 pm
Post
by rajasegar » Wed May 13, 2020 7:48 pm
ssax wrote: I tested on mine with the latest and it's working properly.
Was this a drive that was removed while the system was running? Maybe it still sees it but can't get the statistics on it.
Does it work if you do this?
Code: Select all
/usr/local/nagios/libexec/check_nrpe -u -t 60 -H 10.104.19.120 -P 8192 -p 5666 -c check_drivesize -a 'warn=used>=70' 'crit=used>=85'
Can you try upgrading to the latest on the system and test again?
https://nsclient.org/download/
Code: Select all
[nagios@MYUCBPNAGIAPP01 ~]$ /usr/local/nagios/libexec/check_nrpe -2 -u -t 60 -H 10.104.19.120 -P 8192 -p 5666 -c check_drivesize -a 'warn=used>=70' 'crit=used>=85'
CHECK_NRPE: Receive underflow - only 1026 bytes received (4 expected).
BTW we are already using 0.5.2.39 the latest. Last update was in 2018. Is NSClient++ not updated anymore?
You want me to try the nightly builds?
5 x Nagios 5.6.9 Enterprise Edition
RHEL 6 & 7
rrdcached & ramdisk optimisation
ssax
Dreams In Code
Posts: 7682 Joined: Wed Feb 11, 2015 12:54 pm
Post
by ssax » Thu May 14, 2020 1:27 pm
No, that's correct, they don't update it often but they do work on it. We don't control that because we don't develop that agent (NCPA is our client).
Does this work by chance?
Code: Select all
/usr/local/nagios/libexec/check_nrpe -2 -u -t 60 -H 10.104.19.120 -P 1026 -p 5666 -c check_drivesize -a 'warn=used>=70' 'crit=used>=85'
Please attach (or PM) your latest nsclient.ini so that I can lab it up with yours.
rajasegar
Posts: 1018 Joined: Sun Mar 30, 2014 10:49 pm
Post
by rajasegar » Thu May 14, 2020 10:28 pm
ssax wrote: No, that's correct, they don't update it often but they do work on it. We don't control that because we don't develop that agent (NCPA is our client).
Does this work by chance?
Code: Select all
/usr/local/nagios/libexec/check_nrpe -2 -u -t 60 -H 10.104.19.120 -P 1026 -p 5666 -c check_drivesize -a 'warn=used>=70' 'crit=used>=85'
Please attach (or PM) your latest nsclient.ini so that I can lab it up with yours.
/usr/local/nagios/libexec/check_nrpe -2 -u -t 60 -H 10.104.19.120 -P 1026 -p 5666 -c check_drivesize -a 'warn=used>=70' 'crit=used>=85'
CHECK_NRPE: Response packet had invalid CRC32.
nsclient.ini
This is the disk management screenshot from the server.
disks.png
You do not have the required permissions to view the files attached to this post.
5 x Nagios 5.6.9 Enterprise Edition
RHEL 6 & 7
rrdcached & ramdisk optimisation
ssax
Dreams In Code
Posts: 7682 Joined: Wed Feb 11, 2015 12:54 pm
Post
by ssax » Fri May 15, 2020 2:54 pm
Where are those other ones mounted to?
Open up a admin prompt on that server and PM me the output of these commands: