I am dealing with a weird issue (atleast to me).
I am running nagios-core 4.2.4 and its using init.d script through systemd.
Code: Select all
[root@nagios-core ~]# systemctl status nagios
● nagios.service - LSB: Starts and stops the Nagios monitoring server
Loaded: loaded ([b]/etc/rc.d/init.d/nagios[/b]; bad; vendor preset: disabled)
Active: active (running) since Thu 2019-01-31 06:55:27 UTC; 7h ago
Docs: man:systemd-sysv-generator(8)
Process: 49673 ExecStop=/etc/rc.d/init.d/nagios stop (code=exited, status=0/SUCCESS)
Process: 50505 ExecStart=/etc/rc.d/init.d/nagios start (code=exited, status=0/SUCCESS)
CGroup: /system.slice/nagios.service
├─52109 /usr/local/nagios/bin/nagios -d /usr/local/nagios/etc/nagios.cfg
├─52111 /usr/local/nagios/bin/nagios --worker /usr/local/nagios/var/rw/nagios.qh
As per my understanding "systemd-sysv-generator" creates a service unit for the scripts under "etc/rc.d/init.d/" which is supported by systemd. However I am trying to increase the timeout value of nagios service when started through systemd. The default is 5mins but considering number of devices/services it sometime takes more than that and fails.
Usually for the "nagios.service" under systemd I use "TimeoutSec=15min" to incerease the timeout. However I am not sure how to do this for this one. Can anyone shed some light on this please?