Date: Wed, 16 May 2001 08:36:24 +0200 (CEST) From: Luigi Rizzo <luigi@info.iet.unipi.it> To: "Patrick O'Reilly" <patrick@mip.co.za> Cc: ipfw@FreeBSD.ORG, Holtor <holtor@yahoo.com>, questions@FreeBSD.ORG Subject: Re: Bandwidth Limiting per IP Message-ID: <200105160636.IAA44066@info.iet.unipi.it> In-Reply-To: <NDBBIMKICMDGDMNOOCAICEOGCHAA.patrick@mip.co.za> from "Patrick O'Reilly" at "May 16, 2001 08:29:46 am"
next in thread | previous in thread | raw e-mail | index | archive | help
> There is additional overhead in processing so many pipes, but if the box in actually, if you use dynamic pipes e.g. ipfw add pipe 1 ip from 10.1.2.0/24 to any ipfw pipe 1 config bw 100Kbit/s mask src-ip 0x000000ff then everything works pretty fast -- the ruleset is short, and the pipe processing overhead is O(log n) where n is the number of _active_ pipes. In cases like these i would also suggest the use of fair queueing, which works well in 4.3 ipfw add queue 1 ip from 10.1.2.0/24 to any ipfw pipe 10 config bw 2Mbit/s ipfw queue 1 config pipe 1 weight 30 mask src-ip 0x000000ff so all active flows get an equal share of the total capacity. > question is doing nothing other than acting as a gateway/router then I doubt > that this will be a real problem. I have a vague memory that someone once > benchmarked a set if ipfw rules and found that with a set of 1000 rules (the > average search would therefore hit at about rule 500) the actual latency > induced was just a few milliseconds. yep -- but the 'mask' mechanism often saves you from using so many rules. cheers luigi -----------------------------------+------------------------------------- Luigi RIZZO, luigi@iet.unipi.it . Dip. di Ing. dell'Informazione http://www.iet.unipi.it/~luigi/ . Universita` di Pisa TEL/FAX: +39-050-568.533/522 . via Diotisalvi 2, 56126 PISA (Italy) Mobile +39-347-0373137 -----------------------------------+------------------------------------- To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-ipfw" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200105160636.IAA44066>