From owner-freebsd-questions@FreeBSD.ORG Wed Feb 25 14:50:56 2004 Return-Path: Delivered-To: freebsd-questions@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id EA0F316A4CE for ; Wed, 25 Feb 2004 14:50:56 -0800 (PST) Received: from tequila.4you.lt (tequila.4you.lt [212.122.68.216]) by mx1.FreeBSD.org (Postfix) with SMTP id A9D7C43D31 for ; Wed, 25 Feb 2004 14:50:55 -0800 (PST) (envelope-from hugle@vkt.lt) Received: (qmail 79137 invoked by uid 0); 25 Feb 2004 22:48:33 -0000 Received: from hugle@vkt.lt by tequila by uid 82 with qmail-scanner-1.20rc1 (. Clear:RC:1:. Processed in 0.703182 secs); 25 Feb 2004 22:48:33 -0000 Received: from unknown (HELO localhost) (213.252.192.162) by tequila.4you.lt with SMTP; 25 Feb 2004 22:48:32 -0000 Date: Thu, 26 Feb 2004 00:50:38 +0200 From: hugle X-Mailer: The Bat! (v2.01) X-Priority: 3 (Normal) Message-ID: <195443522982.20040226005038@vkt.lt> To: Jorn Argelo , freebsd-questions@freebsd.org In-Reply-To: <200402251722.45503.jorn@wcborstel.nl> References: <99416957963.20040225172753@vkt.lt> <200402251722.45503.jorn@wcborstel.nl> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Subject: Re[2]: CPU usege too HIGH X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list Reply-To: hugle List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 25 Feb 2004 22:50:57 -0000 JA> What is behind that server? If there are many servers/clients behind that JA> server that require net access and that box functions as the gateway, then it JA> is not really a surprisement that the loads are so high. nothing behind the server, just clients... I have about 500 users, and this BOX is doint NAT for all of them. JA> Also, how many users are connected to that server? A few users won't bring JA> that much load, but having twenty or thirty of them connected will bring JA> quite a load to the CPU. It would make sense that Squid and NAT are using so JA> much CPU time then. JA> Your script may be small, but if again used by the same thirty people then JA> perl will put quite a load on the server. But this never used to happen for over a mnoth... i had the same count of users. I have 3 internet connections. Even now, when it is 1 o'clock (AM) when everybody sleeps (almost) there is: PID USERNAME PRI NICE SIZE RES STATE TIME WCPU CPU COMMAND 46087 root 63 0 9924K 9636K RUN 677:27 87.74% 87.74% natd 63795 nobody 2 0 305M 305M poll 176:15 5.08% 5.08% squid 60589 root 2 0 692K 388K sbwait 316:23 2.05% 2.05% natd perl# uptime 12:49AM up 22 days, 3:19, 1 user, load averages: 2.24, 2.15, 1.86 in last week load avarage at night was about 0.40 .... with best wishes Jarek JA> Cheers, JA> Jorn JA> On Wednesday 25 February 2004 16:27, hugle wrote: >> In last past days, users confirmed of big lag in games.. >> I looged into the server, and saw big proccessor usage there: >> >> last pid: 90449; load averages: 5.55, 9.11, 6.74 >> up 21+19:48:35 17:18:34 68 processes: 5 running, >> 63 sleeping >> CPU states: 29.6% user, 0.0% nice, 34.6% system, 35.8% interrupt, 0.0% >> idle Mem: 321M Active, 1313M Inact, 286M Wired, 85M Cache, 199M Buf, 3488K >> Free Swap: 4079M Total, 216K Used, 4079M Free >> >> PID USERNAME PRI NICE SIZE RES STATE TIME WCPU CPU COMMAND >> 46087 root 62 0 8912K 8624K RUN 393:39 28.86% 28.86% natd >> 63795 nobody 62 0 191M 190M RUN 22:38 22.61% 22.61% squid >> 87001 root -6 0 9288K 8756K piperd 0:04 7.57% 7.57% perl >> 60589 root 2 0 672K 368K sbwait 297:12 0.24% 0.24% natd >> 65212 root 66 19 17416K 15684K RUN 89:50 0.00% 0.00% mlnet-real >> >> perl# uptime >> 5:24PM up 21 days, 19:54, 2 users, load averages: 8.05, 11.78, 8.94 >> >> i have a little sciprt running avery 5 minutes.. it uses perl, but.. >> >> why natd is using so much resourses ? >> there I have to dig the problem? >> and why active memory is so low ?;/