Apply configuration doesn't finish

This support forum board is for support questions relating to Nagios XI, our flagship commercial network monitoring solution.
Frédéric GRANAT
Posts: 445
Joined: Mon Nov 19, 2012 11:36 am

Apply configuration doesn't finish

Post by Frédéric GRANAT »

Hi,
I've got a problem with Apply configuration, it doesn't finish.
Please find attached the file reconfig.txt produced by : ./reconfigure_nagios.sh &> reconfig.txt
I tried to run : tail -f /usr/local/nagiosxi/var/cmdsubsys.log &> cmd.txt, but the command never ends.

If I restart my Nagios server, apply configuration works.
You do not have the required permissions to view the files attached to this post.
abrist
Red Shirt
Posts: 8334
Joined: Thu Nov 15, 2012 1:20 pm

Re: Apply configuration doesn't finish

Post by abrist »

The reconfigure looks good. What are your php limits set to?

Code: Select all

grep "memory_limit\|max_execution\|max_input" /etc/php.ini
Former Nagios employee
"It is turtles. All. The. Way. Down. . . .and maybe an elephant or two."
VI VI VI - The editor of the Beast!
Come to the Dark Side.
Frédéric GRANAT
Posts: 445
Joined: Mon Nov 19, 2012 11:36 am

Re: Apply configuration doesn't finish

Post by Frédéric GRANAT »

max_execution_time = 300 ; Maximum execution time of each script, in seconds
max_input_time = 300 ; Maximum amount of time each script may spend parsing request data
memory_limit = 512M ; Maximum amount of memory a script may consume
abrist
Red Shirt
Posts: 8334
Joined: Thu Nov 15, 2012 1:20 pm

Re: Apply configuration doesn't finish

Post by abrist »

Have you waited for a full 300 seconds to verify that apply config is not just taking 5+ minutes?
Former Nagios employee
"It is turtles. All. The. Way. Down. . . .and maybe an elephant or two."
VI VI VI - The editor of the Beast!
Come to the Dark Side.
Frédéric GRANAT
Posts: 445
Joined: Mon Nov 19, 2012 11:36 am

Re: Apply configuration doesn't finish

Post by Frédéric GRANAT »

When I restart the server "Apply configuration" takes 10 seconds to execute.
Even if it takes 5 min to execute, I don't find that it is satisfying.

Frederic
abrist
Red Shirt
Posts: 8334
Joined: Thu Nov 15, 2012 1:20 pm

Re: Apply configuration doesn't finish

Post by abrist »

Frédéric GRANAT wrote:I tried to run : tail -f /usr/local/nagiosxi/var/cmdsubsys.log &> cmd.txt, but the command never ends.
Go ahead and the run the command again. While it is running, apply configuration. After 2+ minutes, kill the tail with ctrl-c and post the cmd.txt file in code wraps.
Former Nagios employee
"It is turtles. All. The. Way. Down. . . .and maybe an elephant or two."
VI VI VI - The editor of the Beast!
Come to the Dark Side.
User avatar
niebais
Posts: 349
Joined: Tue Apr 13, 2010 2:15 pm

Re: Apply configuration doesn't finish

Post by niebais »

Could you post a copy of your httpd error logs here (last 50 lines after running it) ? Also, did you use the Nagios network/router wizard and setup a few big routers with it?
User avatar
lmiltchev
Bugs find me
Posts: 13589
Joined: Mon May 23, 2011 12:15 pm

Re: Apply configuration doesn't finish

Post by lmiltchev »

Thanks, niebais!
Be sure to check out our Knowledgebase for helpful articles and solutions!
Frédéric GRANAT
Posts: 445
Joined: Mon Nov 19, 2012 11:36 am

Re: Apply configuration doesn't finish

Post by Frédéric GRANAT »

Hi,
Still have the problem.

Go ahead and the run the command again. While it is running, apply configuration. After 2+ minutes, kill the tail with ctrl-c and post the cmd.txt file in code wraps.
=>
Here's the content of : tail -f /usr/local/nagiosxi/var/cmdsubsys.log &> cmd.txt

[root@nagiosxi ~]# vi cmd.txt
PHP Warning: Module 'SourceGuardian' already loaded in Unknown on line 0
PROCESSING COMMAND ID 3285...
Setting new htaccess credentials
Updating password for user nagiosadmin
/usr/bin/htpasswd: unable to update file /usr/local/nagiosxi/etc/htpasswd.users
OUTPUT=
RETURNCODE=1
...........................................................
PROCESSED 1 COMMANDS


It seems there's an overload on the server (because the problem occurs after a delay).
HEre's the output of the command top (winbind high CPU usage, even if Apply config is not running)
PID USER PR NI VIRT RES SHR S %CPU %MEM TIME+ COMMAND
4216 root 25 0 12216 2380 1612 S 99.5 0.1 18502:47 winbindd

Additional information : we've just noticed that our Nagios XI server is not in the AD domain and queries machines in the domain, maybe we should add it to the domain ?
yancy
Posts: 523
Joined: Thu Oct 06, 2011 10:12 am

Re: Apply configuration doesn't finish

Post by yancy »

Hello,

There is no advantage to joining Nagios to the domain in order to query domain members.

Code: Select all

Updating password for user nagiosadmin
/usr/bin/htpasswd: unable to update file /usr/local/nagiosxi/etc/htpasswd.users
did you try changing your nagiosadmin password at some point? does this user account work properly?

-Yancy
Locked