All of lore.kernel.org
 help / color / mirror / Atom feed
* [LARTC] imprecision in bandwidth measurement
@ 2003-12-05 16:51 Tilman Giese (Global View)
  2003-12-05 17:10 ` Stef Coene
                   ` (3 more replies)
  0 siblings, 4 replies; 5+ messages in thread
From: Tilman Giese (Global View) @ 2003-12-05 16:51 UTC (permalink / raw)
  To: lartc

Hi,

I am experiencing a curious phenomenon. I limited the bandwidth for a 
specific client to 750KBit. It works well despite of the fact that the 
client always gets a little bit more bandwidth (around 770KBit to 
780KBit). I used different bandwidth and traffic measurement tools like 
ntop, nettimer or ipac. All show the same, a little bit more bandwidth 
than allowed. The factor by which the specified bandwidth is increased 
seems to be proportional to the specified bandwidth. But where is the 
problem. Is it only a different way of traffic measurement or is this a 
bug? Maybe, does it depend on some command arguments to create the classes?

Tilman

_______________________________________________
LARTC mailing list / LARTC@mailman.ds9a.nl
http://mailman.ds9a.nl/mailman/listinfo/lartc HOWTO: http://lartc.org/

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [LARTC] imprecision in bandwidth measurement
  2003-12-05 16:51 [LARTC] imprecision in bandwidth measurement Tilman Giese (Global View)
@ 2003-12-05 17:10 ` Stef Coene
  2003-12-05 17:23 ` Tilman Giese (Global View)
                   ` (2 subsequent siblings)
  3 siblings, 0 replies; 5+ messages in thread
From: Stef Coene @ 2003-12-05 17:10 UTC (permalink / raw)
  To: lartc

On Friday 05 December 2003 17:51, Tilman Giese (Global View) wrote:
> Hi,
>
> I am experiencing a curious phenomenon. I limited the bandwidth for a
> specific client to 750KBit. It works well despite of the fact that the
> client always gets a little bit more bandwidth (around 770KBit to
> 780KBit). I used different bandwidth and traffic measurement tools like
> ntop, nettimer or ipac. All show the same, a little bit more bandwidth
> than allowed. The factor by which the specified bandwidth is increased
> seems to be proportional to the specified bandwidth. But where is the
> problem. Is it only a different way of traffic measurement or is this a
> bug? Maybe, does it depend on some command arguments to create the classes?
Can you post us your tc commands ?

Stef

-- 
stef.coene@docum.org
 "Using Linux as bandwidth manager"
     http://www.docum.org/
     #lartc @ irc.openprojects.net

_______________________________________________
LARTC mailing list / LARTC@mailman.ds9a.nl
http://mailman.ds9a.nl/mailman/listinfo/lartc HOWTO: http://lartc.org/

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [LARTC] imprecision in bandwidth measurement
  2003-12-05 16:51 [LARTC] imprecision in bandwidth measurement Tilman Giese (Global View)
  2003-12-05 17:10 ` Stef Coene
@ 2003-12-05 17:23 ` Tilman Giese (Global View)
  2003-12-05 18:17 ` Stef Coene
  2003-12-05 19:44 ` Patrick McHardy
  3 siblings, 0 replies; 5+ messages in thread
From: Tilman Giese (Global View) @ 2003-12-05 17:23 UTC (permalink / raw)
  To: lartc

Stef Coene wrote:

>Can you post us your tc commands ?
>  
>
# tc qdisc add dev eth0 root handle 1: cbq bandwidth 10MBit allot 1514 
cell 8 avpkt 1000 mpu 64
# tc filter add dev eth0 parent 1:0 prio 5 protocol ip u32

# tc class add dev eth0 parent 1:0 classid 1:1 cbq bandwidth 10MBit rate 
10MBit allot 1514 cell 8 weight 1MBit prio 5 maxburst 20 avpkt 1000 bounded
# tc class add dev eth0 parent 1:1 classid 1:2 cbq bandwidth 750KBit 
rate 750KBit avpkt 1000 cell 8 prio 5 allot 1514 weight 75KBit maxburst 
21 bounded
# tc class add dev eth0 parent 1:2 classid 1:3 cbq bandwidth 750KBit 
rate 50KBit avpkt 1000 cell 8 prio 5 allot 1514 weight 5KBit maxburst 21

# tc filter add dev eth0 parent 1: prio 5 u32 match ip src 
192.168.0.33/32 flowid 1:3

Tilman



_______________________________________________
LARTC mailing list / LARTC@mailman.ds9a.nl
http://mailman.ds9a.nl/mailman/listinfo/lartc HOWTO: http://lartc.org/

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [LARTC] imprecision in bandwidth measurement
  2003-12-05 16:51 [LARTC] imprecision in bandwidth measurement Tilman Giese (Global View)
  2003-12-05 17:10 ` Stef Coene
  2003-12-05 17:23 ` Tilman Giese (Global View)
@ 2003-12-05 18:17 ` Stef Coene
  2003-12-05 19:44 ` Patrick McHardy
  3 siblings, 0 replies; 5+ messages in thread
From: Stef Coene @ 2003-12-05 18:17 UTC (permalink / raw)
  To: lartc

On Friday 05 December 2003 18:23, Tilman Giese (Global View) wrote:
> Stef Coene wrote:
> >Can you post us your tc commands ?
>
> # tc qdisc add dev eth0 root handle 1: cbq bandwidth 10MBit allot 1514
> cell 8 avpkt 1000 mpu 64
> # tc filter add dev eth0 parent 1:0 prio 5 protocol ip u32
>
> # tc class add dev eth0 parent 1:0 classid 1:1 cbq bandwidth 10MBit rate
> 10MBit allot 1514 cell 8 weight 1MBit prio 5 maxburst 20 avpkt 1000 bounded
> # tc class add dev eth0 parent 1:1 classid 1:2 cbq bandwidth 750KBit
> rate 750KBit avpkt 1000 cell 8 prio 5 allot 1514 weight 75KBit maxburst
> 21 bounded
> # tc class add dev eth0 parent 1:2 classid 1:3 cbq bandwidth 750KBit
> rate 50KBit avpkt 1000 cell 8 prio 5 allot 1514 weight 5KBit maxburst 21
>
> # tc filter add dev eth0 parent 1: prio 5 u32 match ip src
> 192.168.0.33/32 flowid 1:3
I don't see any error in your scripts.  I did some tests myself and this is 
the result :
http://docum.org/stef.coene/qos/tests/cbq/bounded/bounded.html
I had the same result.  The bandwidth you get is a bit more then the 
configured rate.

Stef

-- 
stef.coene@docum.org
 "Using Linux as bandwidth manager"
     http://www.docum.org/
     #lartc @ irc.openprojects.net

_______________________________________________
LARTC mailing list / LARTC@mailman.ds9a.nl
http://mailman.ds9a.nl/mailman/listinfo/lartc HOWTO: http://lartc.org/

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [LARTC] imprecision in bandwidth measurement
  2003-12-05 16:51 [LARTC] imprecision in bandwidth measurement Tilman Giese (Global View)
                   ` (2 preceding siblings ...)
  2003-12-05 18:17 ` Stef Coene
@ 2003-12-05 19:44 ` Patrick McHardy
  3 siblings, 0 replies; 5+ messages in thread
From: Patrick McHardy @ 2003-12-05 19:44 UTC (permalink / raw)
  To: lartc

Tilman Giese (Global View) wrote:
> Hi,
> 
> I am experiencing a curious phenomenon. I limited the bandwidth for a 
> specific client to 750KBit. It works well despite of the fact that the 
> client always gets a little bit more bandwidth (around 770KBit to 
> 780KBit). I used different bandwidth and traffic measurement tools like 
> ntop, nettimer or ipac. All show the same, a little bit more bandwidth 
> than allowed. The factor by which the specified bandwidth is increased 
> seems to be proportional to the specified bandwidth. But where is the 
> problem. Is it only a different way of traffic measurement or is this a 
> bug? Maybe, does it depend on some command arguments to create the classes?


tc uses 1024 instead of 1000 as factor for kbit (1024^2 for mbit). 
Usually when talking about network equipment kbit means 1000bit/s
and mbit means 1000000bit/s. In your case, 750*24bit/s = 18000bit/s off.
The iproute-rates patch at trash.net/~kaber/hfsc is meant to fix this.

Best regards,
Patrick

_______________________________________________
LARTC mailing list / LARTC@mailman.ds9a.nl
http://mailman.ds9a.nl/mailman/listinfo/lartc HOWTO: http://lartc.org/

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2003-12-05 19:44 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2003-12-05 16:51 [LARTC] imprecision in bandwidth measurement Tilman Giese (Global View)
2003-12-05 17:10 ` Stef Coene
2003-12-05 17:23 ` Tilman Giese (Global View)
2003-12-05 18:17 ` Stef Coene
2003-12-05 19:44 ` Patrick McHardy

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.