Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 19 Aug 2002 15:41:42 -0700
From:      Luigi Rizzo <rizzo@icir.org>
To:        Carlos Carnero <zopewiz@yahoo.com>
Cc:        freebsd-net@FreeBSD.ORG
Subject:   Re: Bandwidth throttling with dummynet(4)
Message-ID:  <20020819154141.A41050@iguana.icir.org>
In-Reply-To: <20020819203323.25886.qmail@web21411.mail.yahoo.com>; from zopewiz@yahoo.com on Mon, Aug 19, 2002 at 01:33:23PM -0700
References:  <20020819203323.25886.qmail@web21411.mail.yahoo.com>

next in thread | previous in thread | raw e-mail | index | archive | help
dummynet pipes use timers heavily, and i suspect that
the timer granularity in vmware might not be as good
as you would want, resulting in a throughput which is
a fraction of what you have configured in the pipes.

Also, 5Kbytes/s is a very low bandwidth, which coupled
with 50 queue slots (~75Kbytes with large packets) will result
in very large RTTs which could in turn trigger useless
retransmissions and timeouts.

I would first check if timing is accurate by setting a delay-only
pipe and seeing if ping times correspond to what you have configured.

Secondly, i would reduce the queue size to something reasonable
e.g. 10Kbytes to avoid the potentially huge RTTs.

	cheers
	luigi

On Mon, Aug 19, 2002 at 01:33:23PM -0700, Carlos Carnero wrote:
> Hi,
> 
> I have a "lab" here where I'm testing (and learning)
> traffic shaping with dummynet(4). I have a Windows XP
> host computer and a couple of VMware virtual
> computers: one running  FreeBSD 4.5-RELEASE-p18, with
> two virtual Ethernet adapters and other running NetBSD
> 1.5.2 with one adapter. My FreeBSD "box" is the
> router/gateway for the NetBSD box, providing
> firewalling and NAT. Pretty much a standard setup, and
> it works OK (you should see the double NATting ;)
> 
> Anyway, I have compiled into the kernel both IP Filter
> and FreeBSD's own ipfw, with the purpose of traffic
> shaping/bandwidth throttling. But the numbers I get
> are not what I expect. For instance, my ipfw rules are
> like:
> 
> pipe 1000 config bw 5KByte/s queue 50
> pipe 1001 config bw 5KByte/s queue 50
> 
> add 50000 pipe 1000 tcp from 192.168.250.3/32 to any
> add 50001 pipe 1001 tcp from any to 192.168.250.3/32
> 
> (192.168.250.3 being the NetBSD "box") But when I
> transfer a file using FTP from the Windows host I get
> _almost_ 1 KByte. Note that I remove the pipes speeds
> reach ~800-900 KByte/s, almost saturating the
> "virtual" Ethernet interfaces. Changing the pipe
> bandwidth to, say 25KByte/s in both pipes yield an FTP
> speed of ~5-6 KByte/s. Is this OK or FTP is that
> inefficient? What other tests can I run to check the
> bandwidth _not_ using FTP?
> 
> IP Filter's ruleset is currently set to pass
> everything as quickly as it can :)
> 
> Thanks a lot,
> Carlos.
> 
> PS. Posting from Yahoo! until I solve some reverse DNS
> bugs I inherited :|
> 
> __________________________________________________
> Do You Yahoo!?
> HotJobs - Search Thousands of New Jobs
> http://www.hotjobs.com
> 
> To Unsubscribe: send mail to majordomo@FreeBSD.org
> with "unsubscribe freebsd-net" in the body of the message

To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-net" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20020819154141.A41050>