apache error

This support forum board is for support questions relating to Nagios XI, our flagship commercial network monitoring solution.
Locked
jbennett
Posts: 522
Joined: Mon Apr 16, 2012 3:00 pm

apache error

Post by jbennett »

In checking the health of a new system, I found the following over and over and over again in my error_log for httpd:

Code: Select all

[Tue Feb 05 14:43:51 2013] [error] [client xxx.xxx.xxx.xxx] PHP Notice:  Undefined variable: class in /usr/local/nagiosxi/html/includes/components/opscreen/merlin.php on line 275, referer: http://lnttavmnag1/nagiosxi/includes/components/opscreen/opscreen.php
Line 275 of /usr/local/nagiosxi/html/includes/components/opscreen/merlin.php

Code: Select all

<tr class="<?php print $class ?>">
Not being a programmer, I'm not sure what steps would be necessary to help resolve this?
sreinhardt
-fno-stack-protector
Posts: 4366
Joined: Mon Nov 19, 2012 12:10 pm

Re: apache error

Post by sreinhardt »

Which version of XI is this for? I see that we have some line changes with the newest one, and would like to be sure that it is resolved correctly.
Nagios-Plugins maintainer exclusively, unless you have other C language bugs with open-source nagios projects, then I am happy to help! Please pm or use other communication to alert me to issues as I no longer track the forum.
jbennett
Posts: 522
Joined: Mon Apr 16, 2012 3:00 pm

Re: apache error

Post by jbennett »

ahh, this is on 1.4.

Should I assume that it is resolved in 1.5b?

We run behind a proxy and I have to jump through hoops to open it back up and let someone else run the update. Thus the reason I don't have the ability to see when a new update is present via the Nagios interface.
jbennett
Posts: 522
Joined: Mon Apr 16, 2012 3:00 pm

Re: apache error

Post by jbennett »

I should note that the issue came about when I started to notice that the 'Whoops!' screen when I click on Tactical Overview, but when I click on Home (where I have Tactical Overview set as my home screen), it will display just fine.
sreinhardt
-fno-stack-protector
Posts: 4366
Joined: Mon Nov 19, 2012 12:10 pm

Re: apache error

Post by sreinhardt »

I see where the issue is coming from. You can modify after line 277

Code: Select all

while ($row = mysql_fetch_array($result)) {
to

Code: Select all

while ($row = mysql_fetch_array($result)) {
$class = "";
Or you can wait for revision 1.6, I would not suggest upgrading to 1.5b as it has a few bugs that are nice if you can avoid them.

edit: 277 compared to my current revision. It would probably be 270ish for you.
Nagios-Plugins maintainer exclusively, unless you have other C language bugs with open-source nagios projects, then I am happy to help! Please pm or use other communication to alert me to issues as I no longer track the forum.
jbennett
Posts: 522
Joined: Mon Apr 16, 2012 3:00 pm

Re: apache error

Post by jbennett »

This appears to have resolved the issues with the error log.

Many thanks!
Locked