From owner-freebsd-net@FreeBSD.ORG Sun Jan 18 00:40:38 2009 Return-Path: Delivered-To: freebsd-net@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 71CA41065670 for ; Sun, 18 Jan 2009 00:40:38 +0000 (UTC) (envelope-from miroslav@svishtov.net) Received: from mail.svishtov.net (mail.svishtov.net [85.217.192.3]) by mx1.freebsd.org (Postfix) with ESMTP id BCB338FC08 for ; Sun, 18 Jan 2009 00:40:37 +0000 (UTC) (envelope-from miroslav@svishtov.net) X-Spam-Status: No, hits=4.8 required=7.5 tests=AWL: -0.847,BAYES_99: 4.07,FORGED_RCVD_HELO: 0.135, RCVD_NUMERIC_HELO: 1.5,TOTAL_SCORE: 4.858 X-Spam-Level: **** Received: from 85.217.212.222 ([85.217.212.222]) by mail.svishtov.net for freebsd-net@freebsd.org; Sun, 18 Jan 2009 02:11:15 +0200 To: freebsd-net@freebsd.org From: "Miroslav Slavkov" Message-ID: <20090118021115.53633c6a@mail.svishtov.net> Date: Sun, 18 Jan 2009 02:11:15 +0200 X-User-Agent: Mozilla/5.0 (Windows; U; Windows NT 6.0; en-US) AppleWebKit/525.19 (KHTML, like Gecko) Chrome/1.0.154.43 Safari/525.19 MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable Subject: dummynet high cpu load X-BeenThere: freebsd-net@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Networking and TCP/IP with FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 18 Jan 2009 00:40:38 -0000 Hello, I have a strange thing going on with dummynet. I'm loading around 11000= pipes. The machine does not forward, generate or receive any traffic. The only= running service is ssh. It's for developing purposes. The thing happening is when loading more than 10700 pipes. The dummynet= process begins to eat around %50 of cpu. If i load only 10000 pipes, it= is using 0% cpu. =20 Some output: # ipfw show 65535 612000 126865054 allow ip from any to any # ipfw pipe show| wc -l 10001 # top -Sd 2 last pid: 35787; load averages: 0.11, 0.17, 0.16 = up 0+11:29:29 01= :53:51 73 processes: 6 running, 53 sleeping, 14 waiting CPU: 0.0% user, 0.0% nice, 25.1% system, 0.2% interrupt, 74.7% idle Mem: 23M Active, 20M Inact, 156M Wired, 48K Cache, 38M Buf, 781M Free Swap: 4096M Total, 4096M Free PID USERNAME THR PRI NICE SIZE RES STATE C TIME WCPU C= OMMAND 12 root 1 171 ki31 0K 16K RUN 0 566:04 99.37% i= dle: cpu0 11 root 1 171 ki31 0K 16K RUN 1 459:35 99.07% i= dle: cpu1 36 root 1 -68 - 0K 16K CPU0 0 343:55 0.00% d= ummynet Still.. while loading the rules (one row per pipe config, with script fo= r pipe counting...) the dummynet process begins to raise the usage after= 4000 or some pipes. It gets to 0% after 10-20 secs. # ipfw pipe show | wc -l 10701 # top -Sd2 last pid: 57219; load averages: 0.32, 0.23, 0.18 = up 0+11:37:13 02= :01:35 73 processes: 5 running, 54 sleeping, 14 waiting CPU: 0.0% user, 0.0% nice, 25.2% system, 0.0% interrupt, 74.8% idle Mem: 23M Active, 21M Inact, 156M Wired, 48K Cache, 38M Buf, 781M Free Swap: 4096M Total, 4096M Free PID USERNAME THR PRI NICE SIZE RES STATE C TIME WCPU C= OMMAND 11 root 1 171 ki31 0K 16K RUN 1 465:48 91.26% i= dle: cpu1 12 root 1 171 ki31 0K 16K RUN 0 568:09 59.38% i= dle: cpu0 36 root 1 -68 - 0K 16K CPU0 0 350:22 51.56% d= ummynet # uname -rp 7.1-STABLE amd64 The system is last updated on 15 Jan 2009. The pipes are simple enough: ipfw pipe X config bw =3F=3F=3F=3FKbit/s Seems strange, because no rules are applied. The load is still around 50= % even if the firewall is turned off with the sysctl option. Any clues=3F