Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 17 Dec 2011 11:20:29 -0500
From:      Jason Hellenthal <jhell@DataIX.net>
To:        Doug Barton <dougb@freebsd.org>
Cc:        freebsd-stable@freebsd.org
Subject:   Re: swi4: clock taking 40% cpu?!?
Message-ID:  <20111217162029.GA3875@DataIX.net>
In-Reply-To: <4EEA5DD0.1040009@FreeBSD.org>
References:  <4EEA5DD0.1040009@FreeBSD.org>

next in thread | previous in thread | raw e-mail | index | archive | help


On Thu, Dec 15, 2011 at 12:51:28PM -0800, Doug Barton wrote:
> Howdy,
> 
> Web server under heavy'ish load (7 on a 2 cpu system) running
> 8.2-RELEASE-p4 i386 I'm seeing this:
> 
> PID USERNAME PRI NICE   SIZE    RES STATE   C   TIME   WCPU COMMAND
> 12  root     -32    -     0K   112K WAIT    0 129:01 39.99% {swi4: clock}
> 
> Any ideas why the clock should be taking so much cpu? HZ=100 if that
> makes a difference ...
> 
> 

Without NTPd running test the following.


apply "/usr/bin/time -ph sleep %1" 300 600 900

If the results are skewed quite a bit then your system may benefit from a different HZ than what you have set. I have seen systems that require a HZ of 350 and as weird as it sounds NTPd may be tasting the clock too much just to try and keep time.

-- 
;s =;



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20111217162029.GA3875>