From owner-freebsd-questions@FreeBSD.ORG Wed Apr 2 04:12:15 2008 Return-Path: Delivered-To: freebsd-questions@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id B3D28106566B for ; Wed, 2 Apr 2008 04:12:15 +0000 (UTC) (envelope-from Admin@The-IRC.Org) Received: from Eden.The-IRC.Org (Eden.The-IRC.Org [66.252.7.130]) by mx1.freebsd.org (Postfix) with ESMTP id 8D1968FC19 for ; Wed, 2 Apr 2008 04:12:15 +0000 (UTC) (envelope-from Admin@The-IRC.Org) Received: from s010600195b525564.ls.shawcable.net ([24.109.106.9] helo=rds22612f8a7fe) by Eden.The-IRC.Org with esmtpsa (TLSv1:RC4-MD5:128) (Exim 4.69 (FreeBSD)) (envelope-from ) id 1Jgu1F-000DJK-EF for freebsd-questions@freebsd.org; Tue, 01 Apr 2008 22:52:13 -0500 From: "The-IRC Hosting Administration Team" To: References: <20080401181836.13596owuuxf9az48@mail.top-consulting.net> <20080401235522.GT21480@hal.rescomp.berkeley.edu> In-Reply-To: <20080401235522.GT21480@hal.rescomp.berkeley.edu> Date: Tue, 1 Apr 2008 23:52:12 -0400 Message-ID: <003301c89474$efde4e60$cf9aeb20$@Org> MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit X-Mailer: Microsoft Office Outlook 12.0 Thread-Index: AciUVEeh2dOZEP03TgSftYcD21jE3AAIH4YA Content-Language: en-us X-AntiAbuse: This header was added to track abuse, please include it with any abuse report X-AntiAbuse: Primary Hostname - Eden.The-IRC.Org X-AntiAbuse: Original Domain - freebsd.org X-AntiAbuse: Originator/Caller UID/GID - [26 6] / [26 6] X-AntiAbuse: Sender Address Domain - The-IRC.Org X-Source: X-Source-Args: X-Source-Dir: Subject: RE: FreeBSD Traffic Shaping X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: Admin@The-IRC.Org List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 02 Apr 2008 04:12:15 -0000 I have personally tried that before and it did not worked as described, in fact it didn't work at all to limit anything on FBSD6. -----Original Message----- From: owner-freebsd-questions@freebsd.org [mailto:owner-freebsd-questions@freebsd.org] On Behalf Of Christopher Cowart Sent: Tuesday, April 01, 2008 7:55 PM To: freebsd@top-consulting.net Cc: freebsd-questions@freebsd.org Subject: Re: FreeBSD Traffic Shaping freebsd@top-consulting.net wrote: > I am trying to limit the bandwidth available to some connections and > I'm not sure FreeBSD can handle this. Maybe some of you can help. > Here's what I need to have exactly. > > No matter what the number of connections, each connection should have > at most/least 50kbps guaranteed outbound on port 80. > > I've tried dummynet but it doesn't do what I need because if I define > a pipe with 1mbps and if I have 1000 connections, each connection will > have less than 50kbps. > > Any way to do this in FreeBSD ? The ipfw(8) man page describes a "mask" configuration parameter. # /sbin/ipfw pipe 1 config mask src-ip 0xffffffff bw 56Kbit/s This creates a separate dynamic pipe per source ip address. Each pipe has a dedicated 56kbps. The man page implies that the mask can combine fields, so to uniquely identify "each connection", you would mask all bits of source and destination IP and ports. It looks like the "all" keyword might do just the trick. -- Chris Cowart Network Technical Lead Network & Infrastructure Services, RSSP-IT UC Berkeley