[LARTC] tc htb stats

Linux Advanced Routing and Traffic Control

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



David,

 : When I look at the rate my cisco router
 : reports for a 5min avg and I look at a calculated 5min average (30 polls
 : of the tc once every 10sec) for tc they are very different.  The cisco is
 : reported as ~2090kb/s and tc reports my parent as ~251kb/s.

 : Even if I take all the classes separately and add the averages together
 : I get closer but not that much closer.  Is my math wrong?  How does the
 : tc/htb qdisc figure the avg. rate?

$ expr 251 \* 8
2008

Snipped from http://www.docum.org/stef.coene/qos/docs/ :

  "When you use the tc command, you have to remember that mb = 1024 kb =
   1024 * 1024 b = byte/s and that mbit = 1024 kbit = 1024 * 1024 bit =
   bit/s."

Snipped from http://lartc.org/howto/lartc.qdisc.html :

  "Just to prevent confusion, tc uses the following rules for bandwith
   specification:

   mbps = 1024 kbps = 1024 * 1024 bps => byte/s
   mbit = 1024 kbit => kilo bit/s.
   mb = 1024 kb = 1024 * 1024 b => byte
   mbit = 1024 kbit => kilo bit.!

Are you certain your units are the same?  Strangely, the tc command line
tool uses kb for kilobytes/second.  I think 251 kilobytes-per-second is
quite close to 2090 kilobits-per-second.

Bye for now,

-Martin

-- 
Martin A. Brown --- SecurePipe, Inc. --- mabrown@securepipe.com



[Index of Archives]     [LARTC Home Page]     [Netfilter]     [Netfilter Development]     [Network Development]     [Bugtraq]     [GCC Help]     [Yosemite News]     [Linux Kernel]     [Fedora Users]
  Powered by Linux