Bug 143288

Summary: nagios-nrpe service definition is wrong
Product: [openSUSE] SUSE LINUX 10.0 Reporter: Forgotten User 2Xrp_Q7k_A <forgotten_2Xrp_Q7k_A>
Component: OtherAssignee: Wolfgang Rosenauer <wolfgang.rosenauer>
Status: RESOLVED FIXED QA Contact: E-mail List <qa-bugs>
Severity: Normal    
Priority: P5 - None    
Version: Final   
Target Milestone: SUSE Linux 10.1   
Hardware: Other   
OS: SuSE Linux 10.0   
Whiteboard:
Found By: Customer Services Priority:
Business Priority: Blocker: ---
Marketing QA Status: --- IT Deployment: ---
Attachments: Patch for /etc/xinetd.d/nagios-nrpe
SUSE init.d script

Description Forgotten User 2Xrp_Q7k_A 2006-01-15 16:16:33 UTC
nagios-nrpe (version 2.0-112) comes with an xinet.d service definition.

If one enables this definition (e.g., via yast2), start of xinetd fails and one gets an error message in syslog:
Port not specified and can't find service: 9991 with getservbyname

Obviously the service definition in /etc/xinetd.d/nagios-nrpe is incorrect. The service clause must use a name, and must not use a number. Incidentially, the number 9991 would be wrong as service port number anyhow, as nagios-nrpe's port is 5666. An nrpe entry in /etc/services is missing as well.

Btw, the restriction for source address 127.0.0.1 in /etc/xinetd.d/nagios-nrpe is not sensible. *IF* I use nagios-nrpe, I have the nagios server by definition on another system and want to connect from there.

If you look at this package anyhow, you could also please adapt /usr/share/doc/packages/nagios-nrpe/init-script and make a SUSE init.d-script from it (chkconfig values, and rc.status). Currently, that's a Red-Hat script. That's especially sad, as SUSE 9.0 had a working init.d-script that got removed in 9.1 or 9.2.

Cheers, Joachim
Comment 1 Wolfgang Rosenauer 2006-01-16 13:43:12 UTC
I agree for the localhost-only setting (that's the default xinetd setting in the source package).
The port number within the definition worked in the past. If it doesn't anymore that must be because of a change in xinetd. If we don't use a port name we haven't to define a service in /etc/services. 
For the init-script request I can only say that there was never a init script active in this package. I will see what can be done for SUSE Linux 10.1.
Comment 2 Forgotten User 2Xrp_Q7k_A 2006-01-16 14:16:54 UTC
I append a patch to /etc/xinetd.d/nagios-nrpe that makes it work without a new entry in /etc/services. I tested it.

I also append the init.d-script that we're using. It's missing the reload action, though. (I don't remember who made it, maybe one of my staff. I checked the nagios-nrpe package from SUSE 9.0 again, you're right that it was not in.)
Comment 3 Forgotten User 2Xrp_Q7k_A 2006-01-16 14:22:03 UTC
Created attachment 63446 [details]
Patch for /etc/xinetd.d/nagios-nrpe
Comment 4 Forgotten User 2Xrp_Q7k_A 2006-01-16 14:33:24 UTC
Created attachment 63449 [details]
SUSE init.d script

Some actions are missing; most prominent reload. It is a rewrite of the RH script, that's distributed in the doc area.
Comment 5 Wolfgang Rosenauer 2006-01-17 07:39:05 UTC
Just submitted the changes. It should at least appear in beta2 if not in beta1 of SUSE Linux 10.1.