Page 1 of 1

Nagios Core Upgrade

Posted: Sun Aug 23, 2015 5:43 pm
by Pikmin
Hi all,
I've upgraded from Version 4.1.0rc1 to 4.1.1.1 Stable

Code: Select all

wget https://assets.nagios.com/downloads/nagioscore/releases/nagios-4.1.1.tar.gz
tar xvf nagios-4.1.1.tar.gz
cd nagios-4.1.1
./configure --with-command-group=nagcmd
make all
make install
/usr/local/nagios/bin/nagios -v /usr/local/nagios/etc/nagios.cfg
systemctl restart nagios.service
The upgrade went fine except on the web interface there's a new Map link - Map and (Legacy)
When I click on the map it shows all the hosts, I have it set to circular

Now View Status Detail for this Host doesn't appear to be working
The link points to http://192.168.101.150/nagios/status.cgi?host=undefined
When I click on it I get

Code: Select all

Not Found

The requested URL /nagios/status.cgi was not found on this server.
ScriptAlias /nagios/cgi-bin "/usr/local/nagios/sbin"

Code: Select all

ls -l /usr/local/nagios/sbin/
total 5084
-rwxrwxr-x. 1 nagios nagios 316456 Aug 24 08:27 archivejson.cgi
-rwxrwxr-x. 1 nagios nagios 297752 Aug 24 08:27 avail.cgi
-rwxrwxr-x. 1 nagios nagios 296176 Aug 24 08:27 cmd.cgi
-rwxrwxr-x. 1 nagios nagios 264904 Aug 24 08:27 config.cgi
-rwxrwxr-x. 1 nagios nagios 310008 Aug 24 08:27 extinfo.cgi
-rwxrwxr-x. 1 nagios nagios 260992 Aug 24 08:27 histogram.cgi
-rwxrwxr-x. 1 nagios nagios 240376 Aug 24 08:27 history.cgi
-rwxrwxr-x. 1 nagios nagios 240360 Aug 24 08:27 notifications.cgi
-rwxrwxr-x. 1 nagios nagios 318248 Aug 24 08:27 objectjson.cgi
-rwxrwxr-x. 1 nagios nagios 236224 Aug 24 08:27 outages.cgi
-rwxrwxr-x. 1 nagios nagios 236240 Aug 24 08:27 showlog.cgi
-rwxrwxr-x. 1 nagios nagios 310024 Aug 24 08:27 status.cgi
-rwxrwxr-x. 1 nagios nagios 312296 Aug 24 08:27 statusjson.cgi
-rwxrwxr-x. 1 nagios nagios 261056 Aug 24 08:27 statusmap.cgi
-rwxrwxr-x. 1 nagios nagios 252688 Aug 24 08:27 statuswml.cgi
-rwxrwxr-x. 1 nagios nagios 240368 Aug 24 08:27 statuswrl.cgi
-rwxrwxr-x. 1 nagios nagios 260896 Aug 24 08:27 summary.cgi
-rwxrwxr-x. 1 nagios nagios 252704 Aug 24 08:27 tac.cgi
-rwxrwxr-x. 1 nagios nagios 269184 Aug 24 08:27 trends.cgi

Re: Nagios Core Upgrade

Posted: Sun Aug 23, 2015 8:52 pm
by Pikmin
New Map points to
http://192.168.101.150/nagios/status.cgi?host=undefined
http://192.168.101.150/nagios/status.cgi?host=all
http://192.168.101.150/nagios/status.cgi?hostgroup=all

Legacy points to
http://192.168.101.150/nagios/cgi-bin/s ... yle=detail
http://192.168.101.150/nagios/cgi-bin/s ... i?host=all

So the cgi-bin part is missing in the new map?

EDIT:
I found the three links point to this file: /usr/local/nagios/share/map-links.html

Code: Select all

<table border="1" cellpadding="0" cellspacing="0" class="linkBox">
        <tbody>
               	<tr>
                    	<td class="linkBox">
                                <span ng-show="params.root != 'Nagios Process'">
                                        <a ng-href="{{params.cgiurl}}status.cgi?host={{params.host | uriComponentEncode}}" target="_self">
                                                View Status Detail For This Host
                                        </a>
                                        <br/>
                                </span>
                                <a ng-href="{{params.cgiurl}}status.cgi?host=all" target="_self">
                                        View Status Detail For All Hosts
                                </a>
                                <br/>
                                <a ng-href="{{params.cgiurl}}status.cgi?hostgroup=all" target="_self">
                                        View Status Overview For All Hosts
                                </a>
                        </td>
                </tr>
        </tbody>
</table>
I added the cgi-bin to <a ng-href="{{params.cgiurl}}cgi-bin/status.cgi?host={{params.host | uriComponentEncode}}" target="_self"> and seems to be working now. Still not sure about the undefined part, what's it meant to do?

Re: Nagios Core Upgrade

Posted: Mon Aug 24, 2015 2:49 pm
by tmcdonald
Confirmed by our C dev as a bug. I'll make sure a GitHub issue gets filed for this.

Update: @lmiltchev posted it here: https://github.com/NagiosEnterprises/na ... /issues/76

Closing this thread since a bug report has been filed. It should be a quick fix, keep an eye on that issue for updates.

Re: Nagios Core Upgrade

Posted: Mon Aug 24, 2015 4:30 pm
by lmiltchev
FYI, I just filed a bug report on GitHub here:

https://github.com/NagiosEnterprises/na ... /issues/76