From owner-freebsd-current@FreeBSD.ORG Mon Apr 26 14:58:24 2004 Return-Path: Delivered-To: freebsd-current@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 1992116A4D1 for ; Mon, 26 Apr 2004 14:58:24 -0700 (PDT) Received: from geri.cc.fer.hr (geri.cc.fer.hr [161.53.72.107]) by mx1.FreeBSD.org (Postfix) with ESMTP id 29A7843D49 for ; Mon, 26 Apr 2004 14:58:23 -0700 (PDT) (envelope-from ivoras@fer.hr) Received: from fer.hr (geri.cc.fer.hr [161.53.72.107]) by geri.cc.fer.hr (8.12.9p2/8.12.8) with ESMTP id i3QLvS1m033165 for ; Mon, 26 Apr 2004 23:57:29 +0200 (CEST) (envelope-from ivoras@fer.hr) Message-ID: <408D85FD.10809@fer.hr> Date: Mon, 26 Apr 2004 23:58:21 +0200 From: Ivan Voras User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.6b) Gecko/20031205 Thunderbird/0.4 X-Accept-Language: en-us, en MIME-Version: 1.0 To: current@freebsd.org X-Enigmail-Version: 0.83.1.0 X-Enigmail-Supports: pgp-inline, pgp-mime Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit Subject: Dummynet low bandwidth simulation X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Discussions about the use of FreeBSD-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 26 Apr 2004 21:58:24 -0000 I'm trying to see how a web server performes when "attacked" by many low bandwith connections, and my idea is to use dummynet to simulate such conditions from a single client computer on the same (100Mbps) LAN. I've created a pipe: ipfw pipe 1 config bw 56Kbit/s delay 250 queue 20 buckets 1024 mask all My rules are: ipfw pipe 1 tcp from me to webserver dst-port 80 ipfw pipe 1 tcp from webserver 80 to me When I start the benchmark program (siege) with relatively low concurrency (50 clients), everything works as expected, but after increasing to 100+ simultaneous requests, I start getting huge amounts of "read error: Connection reset by peer" and "broken pipe" messages. During that time the load on the web server is low (plenty of idle time and memory). Without traffic shaping, the server handles 250-300 concurrent requests without problems in the same setup. I've tried changing the queue and bucket size (and adding 'noerror'), with no results. Eliminating latency (delay 0) "fixes" the problem, but it's not meaningfull that way. Am I missing something? -- C isn't that hard: void (*(*f[])())() defines f as an array of unspecified size, of pointers to functions that return pointers to functions that return void.