localhost nrpe.cfg problem

This support forum board is for support questions relating to Nagios XI, our flagship commercial network monitoring solution.
Locked
sureshkraj2012
Posts: 65
Joined: Tue Aug 06, 2013 11:06 pm

localhost nrpe.cfg problem

Post by sureshkraj2012 »

Hello,

I am trying to monitor few things through nrpe on my nagios server itself but it shows below error though the command declared in nrpe.cfg

/usr/local/nagios/libexec/check_nrpe -H localhost -t 30 -c check_mem1
NRPE: Command 'check_mem1' not defined

Entry in nrpe.cfg
allowed_hosts=127.0.0.1
command[check_mem1]=/usr/lib64/nagios/plugins/check_memory -w 10 -c 5 -n

am I missing something here or the localhost monitoring have different nrpe setup?
abrist
Red Shirt
Posts: 8334
Joined: Thu Nov 15, 2012 1:20 pm

Re: localhost nrpe.cfg problem

Post by abrist »

Have you restarted nrpe on the remote host? Any change to the nrpe.cfg file requires a daemon restart.
Former Nagios employee
"It is turtles. All. The. Way. Down. . . .and maybe an elephant or two."
VI VI VI - The editor of the Beast!
Come to the Dark Side.
sureshkraj2012
Posts: 65
Joined: Tue Aug 06, 2013 11:06 pm

Re: localhost nrpe.cfg problem

Post by sureshkraj2012 »

I did it but it again shows same command_undefined error
rajesh.mehra
Posts: 35
Joined: Mon Jan 27, 2014 2:38 am
Location: New Delhi, India

Re: localhost nrpe.cfg problem

Post by rajesh.mehra »

Can you please share nrpe.cfg file
scottwilkerson
DevOps Engineer
Posts: 19396
Joined: Tue Nov 15, 2011 3:11 pm
Location: Nagios Enterprises
Contact:

Re: localhost nrpe.cfg problem

Post by scottwilkerson »

You will also need to restart the nrpe process for the changes to take affect.
Former Nagios employee
Creator:
Human Design Website
Get Your Human Design Chart
MSPk
Posts: 317
Joined: Fri Aug 24, 2012 12:03 am

Re: localhost nrpe.cfg problem

Post by MSPk »

You might have to define a command for this service in your nrpe.cfg before you can perform this check
abrist
Red Shirt
Posts: 8334
Joined: Thu Nov 15, 2012 1:20 pm

Re: localhost nrpe.cfg problem

Post by abrist »

Is this an XI related question, or just core?
Former Nagios employee
"It is turtles. All. The. Way. Down. . . .and maybe an elephant or two."
VI VI VI - The editor of the Beast!
Come to the Dark Side.
Locked