Note: This is a public test instance of Red Hat Bugzilla. The data contained within is a snapshot of the live data so any changes you make will not be reflected in the production Bugzilla. Email is disabled so feel free to test any aspect of the site that you want. File any problems you find or give feedback at bugzilla.redhat.com.

Bug 1291555

Summary: Nagios 4.0.8 won't write pid to predefined pidfile
Product: [Fedora] Fedora EPEL Reporter: Peter Bieringer <pb>
Component: nagiosAssignee: Scott Wilkerson <swilkerson>
Status: CLOSED ERRATA QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: medium Docs Contact:
Priority: unspecified    
Version: epel7CC: affix, jose.p.oliveira.oss, lemenkov, linux, nb, ondrejj, shawn.starr, s, swilkerson
Target Milestone: ---   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: nagios-4.0.8-2.el7 Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2016-01-21 04:39:16 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Peter Bieringer 2015-12-15 06:54:22 UTC
Description of problem:
No pidfile is written


Version-Release number of selected component (if applicable):
nagios-4.0.8-1.el7.x86_64


How reproducible:
Always

Steps to Reproduce:
1. restart nagios

Actual results:

ll /var/run/nagios/
total 0

No pidfile written (or updated)


Expected results:
pid written to pidfile


Additional info:

grep lock_file /etc/nagios/nagios.cfg
lock_file=/var/run/nagios.pid

=> only written in daemon mode...


grep -i pid /usr/lib/systemd/system/nagios.service
PIDFile=/var/run/nagios/nagios.pid

=> this option (cleanup of left-over pidfile) is not used in current case because Type=simple according to systemd manual


ll /var/run/ |grep nagios
drwxr-xr-x  2 nagios   nagios       40 15. Dez 07:31 nagios

=> nagios user should be able to create/write a file into directory


I assume problem is that systemd will start nagios in foreground mode, but lock_file is only written in daemon mode by nagios itself

ExecStart=/usr/sbin/nagios /etc/nagios/nagios.cfg


Afair pidfile was written before major update to version 4

Comment 1 Fedora Update System 2015-12-30 02:28:06 UTC
nagios-4.0.8-2.el7 has been submitted as an update to Fedora EPEL 7. https://bodhi.fedoraproject.org/updates/FEDORA-EPEL-2015-eed09b5974

Comment 2 Fedora Update System 2016-01-01 04:21:06 UTC
nagios-4.0.8-2.el7 has been pushed to the Fedora EPEL 7 testing repository. If problems still persist, please make note of it in this bug report.
See https://fedoraproject.org/wiki/QA:Updates_Testing for
instructions on how to install test updates.
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-EPEL-2015-eed09b5974

Comment 3 Fedora Update System 2016-01-21 04:39:03 UTC
nagios-4.0.8-2.el7 has been pushed to the Fedora EPEL 7 stable repository. If problems still persist, please make note of it in this bug report.