./F-startdaemons with Centos8
Posted: Wed Sep 30, 2020 2:41 pm
Couple of days ago in a development project I encountered an issue with NagiosXI install "F-startdaemons" script while testing on Centos8.
The install process will exit with a failure for the ntpd service restart.
Centos8 now handles ntp via chrony and the xi-sys.cfg still lists the dependency as
In the OEM Script
My workaround was to remove the call to $ntpd in the list of services to restart.
Removing this service from the list had no impact on the remaining steps in the install process nor the functionality of the NagiosXI.
--SN
The install process will exit with a failure for the ntpd service restart.
Centos8 now handles ntp via chrony and the xi-sys.cfg still lists the dependency as
Code: Select all
ntpd="ntpd"
Code: Select all
#!/bin/bash -e
. ./xi-sys.cfg
# Was previous step completed?
if [ ! -f installed.importnagiosql ]; then
echo "NagiosQL data was not imported - run previous script" >&2
exit 1
fi
for svc in $httpd nagios npcd [color=#FF0000]$ntpd[/color] $crond; do
if [ ! `command -v systemctl` ]; then
service $svc restart
else
systemctl restart $svc
fi
done
echo "Daemons started OK"
Code: Select all
#!/bin/bash -e
. ./xi-sys.cfg
# Was previous step completed?
if [ ! -f installed.importnagiosql ]; then
echo "NagiosQL data was not imported - run previous script" >&2
exit 1
fi
for svc in $httpd nagios npcd $crond; do
if [ ! `command -v systemctl` ]; then
service $svc restart
else
systemctl restart $svc
fi
done
echo "Daemons started OK"
--SN