Issues with Applying Configuration after import

This support forum board is for support questions relating to Nagios XI, our flagship commercial network monitoring solution.
karunaka
Posts: 6
Joined: Mon Apr 13, 2015 4:23 am

Issues with Applying Configuration after import

Post by karunaka »

Hi,

I am trying to migrate our Nagios Core installation to Nagios XI, which has a total 744 hosts and 2585 services. I followed the documentation and imported all my existing config files and verified them. When I was done with that, I tried "Apply Configuration" which is taking lot of time and it's still running now (It's been running for more than 2 days). Now I started to believe that, there is something wrong with that.

Can someone please help me to find out what's going on there?
Here are some basic details about my installation:
Current Nagios Core version: 3.2.3
Nagios XI version: Nagios XI 2014R2.0
Number of hosts: 744
Number of services: 2585

Please let me know if you need any other details.

Thanks,
Rinosh
tmcdonald
Posts: 9117
Joined: Mon Sep 23, 2013 8:40 am

Re: Issues with Applying Configuration after import

Post by tmcdonald »

Please run the following as root:

Code: Select all

service httpd restart
Then do an Apply Config and run the following:

Code: Select all

tail -f /usr/local/nagiosxi/var/cmdsubsys.log
and post the results.
Former Nagios employee
karunaka
Posts: 6
Joined: Mon Apr 13, 2015 4:23 am

Re: Issues with Applying Configuration after import

Post by karunaka »

Thanks Tmcdonald for your reply.

I have restarted apache and tailing the log you mentioned. I will wait for some time for that to log something in the cmdsubsys.log.

Meantime I checked on the old cmdsubsys.log and following is the output I can see there.

Code: Select all

............................................................
PROCESSED 0 COMMANDS
Thanks,
Rinosh
tmcdonald
Posts: 9117
Joined: Mon Sep 23, 2013 8:40 am

Re: Issues with Applying Configuration after import

Post by tmcdonald »

Did the apply complete successfully this time?

If not, please run the following and post the output:

Code: Select all

cd /usr/local/nagiosxi/scripts
./reconfigure_nagios.sh | tail -20
Former Nagios employee
karunaka
Posts: 6
Joined: Mon Apr 13, 2015 4:23 am

Re: Issues with Applying Configuration after import

Post by karunaka »

I am seeing the following when I ran that command.

Code: Select all

HTTP request sent, awaiting response... 200 OK
Length: unspecified [text/html]
Saving to: \u201cnagiosql.export.monitoring\u201d

    [   <=>                                                                                                                                                      ] 15,311      11.1K/s   in 1.3s    

2015-04-15 00:11:46 (11.1 KB/s) - \u201cnagiosql.export.monitoring\u201d saved [15311]

tar: Removing leading `/' from member names
   Error processing object config files!


***> One or more problems was encountered while processing the config files...

     Check your configuration file(s) to ensure that they contain valid
     directives and data defintions.  If you are upgrading from a previous
     version of Nagios, you should be aware that some variables/definitions
     may have been removed or modified in this version.  Make sure to read
     the HTML documentation regarding the config files, as well as the
     'Whats New' section to find out what has changed.
RET: 1
/usr/local/nagiosxi/nom/checkpoints/nagioscore/errors /usr/local/nagiosxi/scripts
/usr/local/nagiosxi/scripts
LATEST NOM SNAPSHOT: /usr/local/nagiosxi/nom/checkpoints/nagioscore/1426160882.tar.gz
/ /usr/local/nagiosxi/scripts
RESTORING NOM SNAPSHOT : /usr/local/nagiosxi/nom/checkpoints/nagioscore/1426160882.tar.gz
/usr/local/nagiosxi/scripts
RESETTING PERMS
SETUID ROOT OK
User avatar
tgriep
Madmin
Posts: 9190
Joined: Thu Oct 30, 2014 9:02 am

Re: Issues with Applying Configuration after import

Post by tgriep »

Can you run the following command in a shell on your Nagios XI system and post the results back?

Code: Select all

/usr/local/nagios/bin/nagios -v /usr/local/nagios/etc/nagios.cfg
Be sure to check out our Knowledgebase for helpful articles and solutions!
karunaka
Posts: 6
Joined: Mon Apr 13, 2015 4:23 am

Re: Issues with Applying Configuration after import

Post by karunaka »

Here is the output

Code: Select all

Nagios Core 4.0.8
Copyright (c) 2009-present Nagios Core Development Team and Community Contributors
Copyright (c) 1999-2009 Ethan Galstad
Last Modified: 08-12-2014
License: GPL

Website: http://www.nagios.org
Reading configuration data...
   Read main config file okay...
WARNING: Extinfo objects are deprecated and will be removed in future versions
WARNING: Extinfo objects are deprecated and will be removed in future versions
WARNING: Extinfo objects are deprecated and will be removed in future versions
WARNING: Extinfo objects are deprecated and will be removed in future versions
WARNING: Extinfo objects are deprecated and will be removed in future versions
WARNING: Extinfo objects are deprecated and will be removed in future versions
Warning: Duplicate definition found for service 'xxxxxx' on host 'xxxxxx' (config file '/usr/local/nagios/etc/services/xxxx.cfg', starting on line 25)
..........
   Read object config files okay...

Running pre-flight check on configuration data...

Checking objects...
        Checked 6790 services.
Warning: Host 'xxxx' has no default contacts or contactgroups defined!
        Checked 707 hosts.
        Checked 111 host groups.
        Checked 95 service groups.
        Checked 94 contacts.
        Checked 21 contact groups.
        Checked 310 commands.
        Checked 24 time periods.
        Checked 0 host escalations.
        Checked 0 service escalations.
Checking for circular paths...
        Checked 707 hosts
        Checked 0 service dependencies
        Checked 0 host dependencies
        Checked 24 timeperiods
Checking global event handlers...
Checking obsessive compulsive processor commands...
Checking misc settings...

Total Warnings: 1
Total Errors:   0

Things look okay - No serious problems were detected during the pre-flight check
User avatar
lmiltchev
Bugs find me
Posts: 13589
Joined: Mon May 23, 2011 12:15 pm

Re: Issues with Applying Configuration after import

Post by lmiltchev »

Go to Core Config Manager->Tools->Write Config Files->click on "Write", then click on "Verify" and show us the output. Do you see any config errors?
Be sure to check out our Knowledgebase for helpful articles and solutions!
karunaka
Posts: 6
Joined: Mon Apr 13, 2015 4:23 am

Re: Issues with Applying Configuration after import

Post by karunaka »

I am getting the same output which I have pasted in my previous reply. Is there some way I can run 'Apply Configuration' through backend (using some script)?

-Rinosh
User avatar
lmiltchev
Bugs find me
Posts: 13589
Joined: Mon May 23, 2011 12:15 pm

Re: Issues with Applying Configuration after import

Post by lmiltchev »

Run:

Code: Select all

cd /usr/local/nagiosxi/scripts
./reconfigure_nagios.sh > /tmp/debug.txt 2>&1
and post the "debug.txt" file that was generated in the "/tmp/" directory.
Be sure to check out our Knowledgebase for helpful articles and solutions!
Locked