nagios 3.0b3 abnormal cpu load ?

SCHAER Frederic frederic.schaer at cea.fr
Tue Sep 11 09:07:35 CEST 2007


Hi,

 

I agree with you, I reported the problem on the developers' list
yesterday evening :-)

 

I think that there may just be a test missing somewhere in the code :
host checks should be done on hosts if activated in the nagios.cfg file,
but only if a host check command is defined for these hosts...
concerning your question, for now I'm wondering what's the difference
between a host check and a (ping or whatever) service check : for this I
think I have to go deeper in the famous 'rtfm' ;)

 

Cheers

 

________________________________

From: nagios-users-bounces at lists.sourceforge.net
[mailto:nagios-users-bounces at lists.sourceforge.net] On Behalf Of Anthony
Montibello
Sent: Monday, September 10, 2007 6:45 PM
To: nagios-users at lists.sourceforge.net
Subject: Re: [Nagios-users] nagios 3.0b3 abnormal cpu load ?

 

Hi List,

 

First I think this is more appropiate fpr the Developer list so I hope
Ethan has been watching this thread.

 

If your observation is true,

should Nagios have an internal default hostcheck command  or some code
to deactivate hostchecks when no hostcheck command is entered?

 

Tony (author of NC_Net)

 

On 9/10/07, SCHAER Frederic <frederic.schaer at cea.fr> wrote: 

I finally found a solution :

either deactivate the host checks or... define a check_command for the
hosts : with host_checks_enabled and without a check command, nagios
eats all of my CPU, with a command defined, everything is back to
normal... 

 

I wish I saw I had no check_command defined in my host template !

 

Cheers

 

________________________________

From: SCHAER Frederic 
Sent: Monday, September 10, 2007 5:56 PM
To: SCHAER Frederic; nagios-users at lists.sourceforge.net
Subject: RE: [Nagios-users] nagios 3.0b3 abnormal cpu load ?

 

/me again...

 

It seems there is a problem with host checks on my box that causes host
checks to be run continuously on the same host(s) - well it seems that
there is indeed no host check run because one is < always > executing (
? no, it's not ! ). 

 

logs show this for a debug run of just a few seconds :

# grep "A check of this host is already being executed"
/var/log/nagios/nagios.debug | wc -l 

   1709

 

de-activating host checks (execute_host_checks=0)in the nagios.cfg file
frees the CPU, at the cost of host checks... it's good to know, isn't it
? ;) 

Is this really usefull anyway if I define a check_ping service on all
hosts ?

 

Cheers

 

________________________________

From: nagios-users-bounces at lists.sourceforge.net
[mailto:nagios-users-bounces at lists.sourceforge.net ] On Behalf Of SCHAER
Frederic
Sent: Monday, September 10, 2007 12:25 PM
To: nagios-users at lists.sourceforge.net
Subject: Re: [Nagios-users] nagios 3.0b3 abnormal cpu load ?

 

Hi again,

 

There is a difference between the nagios I compiled on the 2.4 kernel /
RHEL3 box on the one hand, and the 2.6 one on Ubuntu on the other hand :

when stracing the nagios process, I can see it's calling the nanosleep()
function - and it then sleeps -, whereas on the 2.4 box I can't see such
a call : I just see this kind of thing (and lots of these) :

 

gettimeofday({1189419621, 161574}, NULL) = 0

time([1189419621])                      = 1189419621

time([1189419621])                      = 1189419621

gettimeofday({1189419621, 183742}, NULL) = 0

gettimeofday({1189419621, 183780}, NULL) = 0

gettimeofday({1189419621, 183814}, NULL) = 0

time([1189419621])                      = 1189419621

gettimeofday({1189419621, 184172}, NULL) = 0

gettimeofday({1189419621, 184326}, NULL) = 0

time([1189419621])                      = 1189419621

time([1189419621])                      = 1189419621

gettimeofday({1189419621, 184734}, NULL) = 0

gettimeofday({1189419621, 184861}, NULL) = 0

gettimeofday({1189419621, 184984}, NULL) = 0

time([1189419621])                      = 1189419621

gettimeofday({1189419621, 185537}, NULL) = 0

gettimeofday({1189419621, 185734}, NULL) = 0

 

Bad thing is that I tried to configure with and without the
-enable-nanosleep or -disable-nanosleep switches, but this apparently
has no effect :'(. 

So it seems nagios is sleeping all the time, eating the CPU... I'm still
trying to see if I can find a way to compile with a "working sleep". 

 

Fred

 

 

________________________________

From: nagios-users-bounces at lists.sourceforge.net
[mailto:nagios-users-bounces at lists.sourceforge.net ] On Behalf Of SCHAER
Frederic
Sent: Friday, September 07, 2007 5:51 PM
To: nagios-users at lists.sourceforge.net
Subject: [Nagios-users] nagios 3.0b3 abnormal cpu load ?

 

Hi,

 

I'm trying to setup a nagios 3.0b3 server, and I configured it with only
one host, one check (ping).

I can successfully start nagios, but I have concerns about the server
cpu load : that's around 99% cpu usage all the time, on a P4 3GHz
machine... 

 

Is there something I could do to decrese this load ? I tried installing
a nagios 2.9 server using the same configuration, and the load caused by
nagios is just ... 0. 

I guess this is a bug in the beta 3 ?

 

Increasing the sleep time in nagios.cfg does not help at all even if I
put sleep_time=2500 (2500 seconds !)

 

Any suggestions would be welcome :-)

 

P.S : I compiled nagios on a 2.4.21 linux kernel, using gcc 3.2.3, don't
know if this could help. I don't see many usefull things with maximum
debug verbosity... 

 

 


------------------------------------------------------------------------
- 
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2005.
http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/
_______________________________________________
Nagios-users mailing list
Nagios-users at lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/nagios-users 
::: Please include Nagios version, plugin version (-v) and OS when
reporting any issue.
::: Messages without supporting info will risk being sent to /dev/null

 

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://www.monitoring-lists.org/archive/users/attachments/20070911/5f458999/attachment.html>
-------------- next part --------------
-------------------------------------------------------------------------
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2005.
http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/
-------------- next part --------------
_______________________________________________
Nagios-users mailing list
Nagios-users at lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/nagios-users
::: Please include Nagios version, plugin version (-v) and OS when reporting any issue. 
::: Messages without supporting info will risk being sent to /dev/null


More information about the Users mailing list