Page 2 of 2

Re: Nagios Core Update Available Banner Not Displayed

Posted: Tue Jan 21, 2014 9:28 am
by Master_Chief_Jon
On 1/17 I told you that I went back to v4.0.1, and that's what's displayed on the status.cgi and the home page. But I noticed this morning that the status.dat file still shows "version=4.0.2". Here is the first few lines of the status.dat file:

Code: Select all

########################################
#          NAGIOS STATUS FILE
#
# THIS FILE IS AUTOMATICALLY GENERATED
# BY NAGIOS.  DO NOT MODIFY THIS FILE!
########################################

info {
        created=1390314319
        version=4.0.2
        last_update_check=1390252677
        update_available=0
        last_version=4.0.2
        new_version=4.0.2
        }
I don't think that our testing is going the be useful until we get that resolved. What do I need to do to get the status.dat file to show v4.0.1?

Re: Nagios Core Update Available Banner Not Displayed

Posted: Tue Jan 21, 2014 5:30 pm
by sreinhardt
Did you happen to remove the status.dat file when reverting versions? Typically nagios will leave changes like that alone, and only do actual status updates from my understanding. My suggestions would be either: (re)move status.dat and allow generation of a new one, or modify the version= line to 4.0.1 to properly reflect this. I will verify in the code that this is the case, regarding it not changing\verifying this change, as that should be corrected.

Re: Nagios Core Update Available Banner Not Displayed

Posted: Wed Jan 22, 2014 8:11 am
by Master_Chief_Jon
Interesting. I looked at the top 20 lines of retention.dat and it shows v4.0.1. So I stopped the nagios service and started it, and the new status.dat file now shows the proper version number.

Code: Select all

########################################
#          NAGIOS STATUS FILE
#
# THIS FILE IS AUTOMATICALLY GENERATED
# BY NAGIOS.  DO NOT MODIFY THIS FILE!
########################################

info {
        created=1390395994
        version=4.0.1
        last_update_check=1390345941
        update_available=1
        last_version=4.0.1
        new_version=4.0.2
        }
So maybe after down-reving Nagios, I needed to restart it a second time (I only restarted it once)?

OK, what next? Would you like to remote to my PC and look at it directly?

Re: Nagios Core Update Available Banner Not Displayed

Posted: Wed Jan 22, 2014 10:45 am
by tmcdonald
Remote sessions are typically reserved for current customers, and those are usually used for Nagios XI.

Is the banner still not showing?

Re: Nagios Core Update Available Banner Not Displayed

Posted: Wed Jan 22, 2014 10:52 am
by Master_Chief_Jon
Regarding remote support, I understand.

The banner is not displayed right now, but I would like to wait 24 hours and try it again (since the update check happens once per 24 hour period).

Re: Nagios Core Update Available Banner Not Displayed

Posted: Wed Jan 22, 2014 5:28 pm
by slansing
Okay, let us know if anything changes. In the meantime we will brainstorm and test on our end when we get a chance to try and reproduce again.

Re: Nagios Core Update Available Banner Not Displayed

Posted: Thu Jan 23, 2014 10:04 am
by Master_Chief_Jon
OK, the banner is still not displayed, and according to the status.dat file, the last update check was performed "Wed, 22 Jan 2014 21:13:11 GMT". Here is the top of the status.dat file:

Code: Select all

########################################
#          NAGIOS STATUS FILE
#
# THIS FILE IS AUTOMATICALLY GENERATED
# BY NAGIOS.  DO NOT MODIFY THIS FILE!
########################################

info {
        created=1390488898
        version=4.0.1
        last_update_check=1390425191
        update_available=1
        last_version=4.0.1
        new_version=4.0.2
        }

Note that if I modify the code in the main.php file so that the line which was originally: //$updateinfo['update_available']=true; is changed to: $updateinfo['update_available']=true;
(in other words un-commenting that line), then the banner is displayed. This tells me that the value "update_available" is not being correctly set to true, and when I override it to true, the banner is displayed.

What next?

Re: Nagios Core Update Available Banner Not Displayed

Posted: Fri Jan 24, 2014 2:55 pm
by sreinhardt
Interesting, I would tend to agree. If it has not been suggested already, I would say post a bug on tracker.nagios.org. Otherwise when I need a break from nagios-plugins this weekend, I will take a look into the core code for this.

Re: Nagios Core Update Available Banner Not Displayed

Posted: Fri Jan 24, 2014 3:59 pm
by Master_Chief_Jon
OK, I submitted it to tracker.nagios.org. It's bug number 563
http://tracker.nagios.org/view.php?id=563

Re: Nagios Core Update Available Banner Not Displayed

Posted: Mon Jan 27, 2014 1:31 pm
by lmiltchev
Thanks for submitting the bug report!