Running the check locally is not nearly the same as having nrpe client make a connection to a remote host, and have that remote host perform the check.
You need to make sure that you are able to make the connection. There are many many topics in this forum that all have had the same trouble. Check the nrpe docs and make sure you have done all that is required to make the connection.
But all others default plugins are working ok.
This new plugin is not working and giving me error.Same this plugin is working on diffenernt machine is working ok.
I am so much confused due to this…
default plugins means check_memory,check_load,check_users,check_procs are running ok.But I create one plugin with name check_mem is not working.It is shell script
#./check_nrpe -H 192.168.10.20 -c check_mem
CHECK_NRPE: Error receiving data from daemon.
./check_nrpe -H 192.168.10.20 -c check_memory
Status: OK - 82% memory free.
./check_nrpe -H 192.168.10.20 -c check_procs
PROCS OK: 94 processes
./check_nrpe -H 192.168.10.20 -c check_users
USERS OK - 3 users currently logged in |users=3;5;10;0
#./check_nrpe -H 192.168.10.20 -c check_mem
CHECK_NRPE: Error receiving data from daemon.
if I execute the same shell script from shell is working very well…like this…
#./check_mem --mem 15 10
MEMORY:15 CRITICAL - System has free memory::2 %(14 mb) from total 475 mb memory
Did you run that from the local or remote. Try it on both, paste the output.
It sounds like the command is not defined. Perhaps restarting the daemon on the remote host would force it to reread the configs.
If that is what is wrong, then the install instructions have not been followed to the letter. Seeing so many problems with nrpe posted here, leeds me to believe, that the install instruction file is name “please_ignore_this_install_instructions.txt_file”. I’ve read through it, and it seems to be very clear, so I really don’t see why all these problems come up.
This seems to be the stock answer to this question, and also the incorrect one.
His other nrpe plugins are working fine, so that cannot be the issue
Also, it says in nrpe.cfg
[blockquote]#NOTE: This option is ignored if NRPE is running under either inetd or xinetd
allowed_hosts=127.0.0.1
[/blockquote]
I am having the same problem with check_dhcp. My other nrpe checks on the same host are working fine. I was wondering if this wasa ever resolved?
If so, I would love to hear the solution. If not, I will post back if I find a solution
My problem was solved, and it was a permissions issue on the check_dhcp plugin
I matched the owner and permissions to the other plugins, and it worked.
Dumb oversight on my part…
Correct, but it the README says:
If your system uses xinetd…
only_from = …
}
So, one way or another, it’s not entirely wrong to make sure that the remote IP is allowed to connect. I’d have to say most of my replies are stock answers too, since most every question can be resolved by reading the docs over again. There are execptions, but in general, yea, my replies are “stock”.
BTW, good fix on that DHCP check. STicky bit to the rescue.