Page 1 of 1

Nagios XI fails to install autodiscovery properly in CentOS7

Posted: Mon May 04, 2015 5:00 pm
by nbdstl
Nagios XI Version: 2014r2.7 [demo]
Host: CentOS Linux release 7.1.1503
Host architecture: 64bit
Install: manual

Problem Description

When trying to run the auto-discovery wizard, I get the following error:
An installation errror was detected. The following steps must be completed before using this component:

Run the setup script. To do this, login to the Nagios XI server as the root user and issue the following commands:

chmod +x /usr/local/nagiosxi/html/includes/components/autodiscovery/setup.sh
/usr/local/nagiosxi/html/includes/components/autodiscovery/setup.sh
Looking at /usr/local/nagiosxi/html/includes/components/autodiscovery/setup.sh, I see

Code: Select all

/etc/init.d/httpd reload
Under CentOS7/RHEL7 the init.d directory is gone. The proper way to do this, which will work under CentOS/RHEL 5 - 7, is:

Code: Select all

service httpd reload
The service command is redirected to systemctl under CentOS7.

Alternatively, check which service management tool is available and invoke service or systemctl as appropriate:

Code: Select all

if [ -e /usr/bin/systemctl ]; then
    /usr/bin/systemctl restart httpd.service
else
    /usr/sbin/service httpd restart
fi
Chris

Re: Nagios XI fails to install autodiscovery properly in Cen

Posted: Mon May 04, 2015 5:09 pm
by jdalrymple
This one is a bit of a no-brainer, thanks for pointing it out so we can get it cleared up ASAP.

Bug report filed.