Memory utilization not showing in HP-UX through NRPE

This support forum board is for support questions relating to Nagios XI, our flagship commercial network monitoring solution.
progressive.nagiosXI
Posts: 277
Joined: Mon Jul 31, 2017 5:54 am

Memory utilization not showing in HP-UX through NRPE

Post by progressive.nagiosXI »

Hi Team,

PFA,
we installed and configured nrpe agent on HP-UX but not getting any value for Memory Utilization its showing blank

Note : we are getting values for File system and CPU

Please help!!
Thanks
You do not have the required permissions to view the files attached to this post.
npolovenko
Support Tech
Posts: 3457
Joined: Mon May 15, 2017 5:00 pm

Re: Memory utilization not showing in HP-UX through NRPE

Post by npolovenko »

Hello, @progressive.nagiosXI. Let's increase permissions for the check_memory.pl plugin on the remote NRPE server.
chmod 777 /usr/local/nagios/libexec/check_memory.pl
chmod u+x /usr/local/nagios/libexec/check_memory.pl
Then on the remote server sign in as nagios user and execute the plugin:
su - nagios
/usr/local/nagios/libexec/check_memory.pl
As of May 25th, 2018, all communications with Nagios Enterprises and its employees are covered under our new Privacy Policy.
progressive.nagiosXI
Posts: 277
Joined: Mon Jul 31, 2017 5:54 am

Re: Memory utilization not showing in HP-UX through NRPE

Post by progressive.nagiosXI »

Have tried this using the command with nagios user and given permission or 777.

As we can see nagios xi is running the command and also getting the actual state ( ok or critical ) its only missing the binary number.
ssax
Dreams In Code
Posts: 7682
Joined: Wed Feb 11, 2015 12:54 pm

Re: Memory utilization not showing in HP-UX through NRPE

Post by ssax »

The output from the nagios screenshot and the output from the command you ran (check_memory.pl) does not look like it's the same plugin, please attach the plugin that is used for the check_mem command in your nrpe.cfg file on the HP-UX server so that we can debug further.

Thank you
progressive.nagiosXI
Posts: 277
Joined: Mon Jul 31, 2017 5:54 am

Re: Memory utilization not showing in HP-UX through NRPE

Post by progressive.nagiosXI »

snapshots are different because we have tried two plugins,


The first plugin is check_mem ==> by running this we are getting the wrong output as its always showing this

[[email protected] ~]$ /usr/local/nagios/libexec/check_nrpe -H 10.200.4.161 -t 30 -c check_mem -a ' -w 80 -c 90 '
OK - System Memory is at % |memory=;90;80;00;80

No Matter if the actual is in the warning state or critical and also not giving any number, but the plugin is running absolutely fine in command line
User avatar
lmiltchev
Bugs find me
Posts: 13589
Joined: Mon May 23, 2011 12:15 pm

Re: Memory utilization not showing in HP-UX through NRPE

Post by lmiltchev »

How is "check_mem" command defined in nrpe.cfg on the remote box?

What is the output of the following command, run from the CLI on the HP-UX box?

Code: Select all

cat /etc/shells
Be sure to check out our Knowledgebase for helpful articles and solutions!
progressive.nagiosXI
Posts: 277
Joined: Mon Jul 31, 2017 5:54 am

Re: Memory utilization not showing in HP-UX through NRPE

Post by progressive.nagiosXI »

Hi Team,

Sorry for delay in response, please find attached NRPE>cfg file and we are not able to run command cat /etc/shells in HP-UX box.
You do not have the required permissions to view the files attached to this post.
User avatar
lmiltchev
Bugs find me
Posts: 13589
Joined: Mon May 23, 2011 12:15 pm

Re: Memory utilization not showing in HP-UX through NRPE

Post by lmiltchev »

The "check_mem" command is defined as such:

Code: Select all

command[check_mem]=/usr/local/nagios/libexec/check_mem $ARG1$
so, let's try to run the plugin locally (on the remote box), and check the output:

Code: Select all

/usr/local/nagios/libexec/check_mem -w 80 -c 90
Also, run the following commands on the remote machine and show the output:

Code: Select all

swapinfo -m
swapinfo -m | grep memory |  sed 's/'%'//' | awk '{ print $5 }'
Be sure to check out our Knowledgebase for helpful articles and solutions!
progressive.nagiosXI
Posts: 277
Joined: Mon Jul 31, 2017 5:54 am

Re: Memory utilization not showing in HP-UX through NRPE

Post by progressive.nagiosXI »

Hi Team,

Please find output

HSOLMANDEV:/usr/local/nagios/libexec #./check_mem -w 80 -c 90
OK - System Memory is at 10% |memory=10;90;80;00;80
HSOLMANDEV:/usr/local/nagios/libexec #

HSOLMANDEV:/usr/local/nagios/libexec #/usr/local/nagios/libexec/check_mem -w 80 -c 90
OK - System Memory is at 10% |memory=10;90;80;00;80
HSOLMANDEV:/usr/local/nagios/libexec #



output of

HSOLMANDEV:/usr/local/nagios/libexec #swapinfo -m | grep memory | sed 's/'%'//' | awk '{ print $5 }'
10



output of swapinfo

HSOLMANDEV:/usr/local/nagios/libexec #swapinfo -m
Mb Mb Mb PCT START/ Mb
TYPE AVAIL USED FREE USED LIMIT RESERVE PRI NAME
dev 16384 0 16384 0% 0 - 1 /dev/vg00/lvol2
reserve - 455 -455
memory 62330 6298 56032 10%
Locked