Page 1 of 2

Upgrade errors II

Posted: Fri Sep 12, 2014 4:49 am
by Narie
Unfortunately another upgrade trial failed. The configuration check before the upgrade shows no errors.

I have attached the relevant messages

Code: Select all

***VERSION BEFORE UPGRADE***
[root@NAGIOSXI-SERVER nagiosxi]# /usr/local/nagios/bin/nagios -V

Nagios Core 3.5.0
Copyright (c) 2009-2011 Nagios Core Development Team and Community Contributors
Copyright (c) 1999-2009 Ethan Galstad
Last Modified: 03-15-2013
License: GPL

***RESULT OF PRE UPGRADE CHECK***
   Read object config files okay...

Running pre-flight check on configuration data...

Checking services...
        Checked 1127 services.
Checking hosts...
        Checked 245 hosts.
Checking host groups...
        Checked 14 host groups.
Checking service groups...
        Checked 1 service groups.
Checking contacts...
        Checked 5 contacts.
Checking contact groups...
        Checked 3 contact groups.
Checking service escalations...
        Checked 0 service escalations.
Checking service dependencies...
        Checked 0 service dependencies.
Checking host escalations...
        Checked 0 host escalations.
Checking host dependencies...
        Checked 0 host dependencies.
Checking commands...
        Checked 111 commands.
Checking time periods...
        Checked 11 time periods.
Checking for circular paths between hosts...
Checking for circular host and service dependencies...
Checking global event handlers...
Checking obsessive compulsive processor commands...
Checking misc settings...

Total Warnings: 0
Total Errors:   0

***START UPGRADE***
[root@NAGIOSXI-SERVER nagiosxi]# ./upgrade
PHP Deprecated:  Comments starting with '#' are deprecated in /etc/php.ini on line 946 in Unknown on line 0
PHP Deprecated:  Comments starting with '#' are deprecated in /etc/php.d/mcrypt.ini on line 2 in Unknown on line 0
PHP Deprecated:  Comments starting with '#' are deprecated in /etc/php.ini on line 946 in Unknown on line 0
PHP Deprecated:  Comments starting with '#' are deprecated in /etc/php.d/mcrypt.ini on line 2 in Unknown on line 0
Checking required prereqs...
Please wait...

OLD VERSION: 320
===================
2014 Updates
===================

*** Exfoliation theme installed ***
NOTE: Use 'make install-classicui' to revert to classic Nagios theme

make[1]: Leaving directory `/tmp/nagiosxi/subcomponents/nagioscore/nagios-4.0.8'
make install-basic
make[1]: Entering directory `/tmp/nagiosxi/subcomponents/nagioscore/nagios-4.0.8'
/usr/bin/install -c -m 775 -o nagios -g nagios -d /usr/local/nagios/libexec
/usr/bin/install -c -m 775 -o nagios -g nagios -d /usr/local/nagios/var
/usr/bin/install -c -m 775 -o nagios -g nagios -d /usr/local/nagios/var/archives
/usr/bin/install -c -m 775 -o nagios -g nagcmd -d /usr/local/nagios/var/spool/checkresults
chmod g+s /usr/local/nagios/var/spool/checkresults

*** Main program, CGIs and HTML files installed ***

You can continue with installing Nagios as follows (type 'make'
without any arguments for a list of all possible options):

  make install-init
     - This installs the init script in /etc/rc.d/init.d

  make install-commandmode
     - This installs and configures permissions on the
       directory for holding the external command file

  make install-config
     - This installs sample config files in /usr/local/nagios/etc

make[1]: Leaving directory `/tmp/nagiosxi/subcomponents/nagioscore/nagios-4.0.8'
Running configuration check... CONFIG ERROR!  Restart aborted.  Check your Nagios configuration.

Re: Upgrade errors II

Posted: Fri Sep 12, 2014 9:08 am
by tmcdonald
Go to Configure -> Core Config Manager, then on the left under Tools click Write Config Files. Then click Verify and post a screenshot.

Re: Upgrade errors II

Posted: Sat Sep 13, 2014 6:40 am
by Narie
The file is attached.

Re: Upgrade errors II

Posted: Mon Sep 15, 2014 9:00 am
by Box293
Go to the CLI on your Nagios box and delete that file:

Code: Select all

rm /usr/local/nagios/etc/services/Internet-diensten.cfg
Repeat tmcdonald's steps again to find if there any any more files it has issues with.

Once you've done this attempt the upgrade again.

Re: Upgrade errors II

Posted: Mon Sep 15, 2014 9:49 am
by Narie
Box293 wrote:Go to the CLI on your Nagios box and delete that file:

Code: Select all

rm /usr/local/nagios/etc/services/Internet-diensten.cfg
Repeat tmcdonald's steps again to find if there any any more files it has issues with.

Once you've done this attempt the upgrade again.
Thanks for the reply. Once I've remove the first (internet-diensten) template it starts about the default templates, such as hosttemplates and servciestemplates, which shouldn't be removed, I think. I have just rolled back my VMware snapshot to go back to a working system.
Just to be clear, when I check on the system before the upgrade, (Configure/Core Config Manager/Write Config Files/Write-Verify) there are no errors.

Re: Upgrade errors II

Posted: Mon Sep 15, 2014 12:46 pm
by tmcdonald
No errors before an upgrade usually means no errors after an upgrade. This is assuming you have applied config and all of the files have been written to disk, meaning there are no changes in the CCM that have not been committed.

Re: Upgrade errors II

Posted: Mon Sep 15, 2014 2:34 pm
by Box293
Before you attempt your next upgrade, I would do the following:
  • Go into CCM
    Tools > Write Config Files
    Click the Delete button
    It will say "Successfully deleted all Host / Service Config Files"
    Click the Write Button
    It will show an output of all the files it creates
    Click the Verify button
    The output should end with "Total Errors: 0"
    Quick Tools > Apply Configuration
    Click the Apply Configuration button
Then perform the upgrade.

Let us know how you go.

Re: Upgrade errors II

Posted: Tue Sep 16, 2014 7:09 am
by Narie
Box293 wrote:Before you attempt your next upgrade, I would do the following:
  • Go into CCM
    Tools > Write Config Files
    Click the Delete button
    It will say "Successfully deleted all Host / Service Config Files"
    Click the Write Button
    It will show an output of all the files it creates
    Click the Verify button
    The output should end with "Total Errors: 0"
    Quick Tools > Apply Configuration
    Click the Apply Configuration button
Then perform the upgrade.

Let us know how you go.
Thanks for your reply. Can you please tell me where the "Delete" button is? (Please see my screenshot)

Re: Upgrade errors II

Posted: Tue Sep 16, 2014 9:11 am
by Box293
My apologies, in the older versions the Delete button isn't there.

These two commands do the same as the delete button:

rm -f /usr/local/nagios/etc/hosts/*.*
rm -f /usr/local/nagios/etc/services/*.*

Once you've done this, continue with the steps I've listed (write, verify, apply).

Re: Upgrade errors II

Posted: Tue Sep 16, 2014 9:48 am
by Narie
Box293 wrote:My apologies, in the older versions the Delete button isn't there.

These two commands do the same as the delete button:

rm -f /usr/local/nagios/etc/hosts/*.*
rm -f /usr/local/nagios/etc/services/*.*

Once you've done this, continue with the steps I've listed (write, verify, apply).
Ok, so I've run both commands.

The write action runs without a problem (please see attachment)

After applying the write action worked as well. However, after running the upgrade again, it came back at the same point with an error:

Code: Select all

*** Main program, CGIs and HTML files installed ***

You can continue with installing Nagios as follows (type 'make'
without any arguments for a list of all possible options):

  make install-init
     - This installs the init script in /etc/rc.d/init.d

  make install-commandmode
     - This installs and configures permissions on the
       directory for holding the external command file

  make install-config
     - This installs sample config files in /usr/local/nagios/etc

make[1]: Leaving directory `/tmp/nagiosxi/subcomponents/nagioscore/nagios-4.0.8'
Running configuration check... CONFIG ERROR!  Restart aborted.  Check your Nagios configuration.