TC HTB r2q
HTB:
quantum of class 10001 is big. Consider r2q change.
根据HTB的官方文档显示,quantum是在可以“借”的情况下,一次可以“借”多少,并且说这个值最好尽量的小,但要大于MTU;而且这个值是不用手动设置,它会根据r2q的值计算出来。
Changing burst will not remove the warning. r2q is "rate to quantum" is used
to calculate the quantum for each class : quantum = rate / r2q. Quantum must
be 1500 < quantum < 60000. Otherwise you will get warnings from the kernel.
Solution : choose r2q so for each class 1500 < quantum < 60000
Or choose the best r2q you can and specify the quantum manually if you add a
class.
> tc qdisc add dev eth0 root handle 1: htb default 10
Default r2q = 10.
> tc class add dev eth0 parent 1: classid 1:1 htb rate 100mbit burst 2k
> tc class add dev eth0 parent 1:1 classid 1:10 htb rate 80mbit ceil 100mbit
> burst 2k
>
> tc class add dev eth0 parent 1:1 classid 1:11 htb rate 128kbit burst 2k
> tc class add dev eth0 parent 1:11 classid 1:21 htb rate 16kbit ceil 56kbit
> burst 2k
> tc class add dev eth0 parent 1:11 classid 1:22 htb rate 16kbit ceil 40kbit
> burst 2k
> tc class add dev eth0 parent 1:11 classid 1:23 htb rate 16kbit ceil 72kbit
> burst 2k
> tc class add dev eth0 parent 1:11 classid 1:24 htb rate 16kbit ceil 64kbit
> burst 2k
> tc class add dev eth0 parent 1:11 classid 1:25 htb rate 16kbit ceil 40kbit
> burst 2k
> tc class add dev eth0 parent 1:11 classid 1:26 htb rate 16kbit ceil 40kbit
> burst 2k
> tc class add dev eth0 parent 1:11 classid 1:27 htb rate 16kbit ceil 32kbit
> burst 2k
> tc class add dev eth0 parent 1:11 classid 1:28 htb rate 16kbit ceil 56kbit
> burst 2k
Smallest rate : 16kbit = 2 kilobyt / r2q (=10) = 200. And this is < 1500. So
you get warnings.
Biggest rate : 100mbit = 12.5 mbyte / r2q = 1.2 Mbyte > 60.000. So you get
warnings.
If you do
tc qdisc add dev eth0 root handle 1: htb default 10 r2q 1
Smallest rate : 16kbit = 2kilobyte / r2k = 2000. And this is > 1500. So no
warnings.
Biggest rate : 100mbit = 12.5 mbyte / r2q = 12.5 Mbyte > 60.000. So you get
warnings. But you can overrule the quantum :
tc class add dev eth0 parent 1:1 classid 1:11 htb rate 128kbit burst 2k
quantum 60000
Quantum is used when 2 classes are getting more bandwidth then the rate. So
it's only important for sharing the remaining bandwidth. In that case, each
class may send quantum bytes.
TC HTB r2q的更多相关文章
- linux 下使用 tc 模拟网络延迟和丢包(转)
1 模拟延迟传输简介 netem 与 tc: netem 是 Linux 2.6 及以上内核版本提供的一个网络模拟功能模块.该功能模块可以用来在性能良好的局域网中,模拟出复杂的互联网传输性能,诸如低带 ...
- linux 下使用 tc 模拟网络延迟和丢包
1 模拟延迟传输简介 netem 与 tc: netem 是 Linux 2.6 及以上内核版本提供的一个网络模拟功能模块.该功能模块可以用来在性能良好的局域网中,模拟出复杂的互联网传输性能,诸如低带 ...
- linux 流量控制全攻略(TC)
TC很是强大啊,很多所谓的硬件路由器,都是基于这个做的. TC介绍 在linux中,TC有二种控制方法CBQ和HTB.HTB是设计用来替换CBQ的.它是一个层次式的过滤框架.TC包括三个基本的构成块: ...
- 【转载】linux下使用 TC 对服务器进行流量控制
tc 介绍 在linux中,tc 有二种控制方法 CBQ 和 HTB.HTB 是设计用来替换 CBQ 的.HTB比CBQ更加灵活,但是CPU 开销也更大,通常高速的链路会使用CBQ,一般而言HTB使用 ...
- iproute2和tc的高级路由用法
#Linux advanced router ip link show #显示链路 ip addr show #显示地址(或ifconfig) ip route show #显示路由(route -n ...
- linux下使用 TC 对服务器进行流量控制
tc 介绍 在linux中,tc 有二种控制方法 CBQ 和 HTB.HTB 是设计用来替换 CBQ 的.HTB比CBQ更加灵活,但是CPU 开销也更大,通常高速的链路会使用CBQ,一般而言HTB使用 ...
- tc/traffic control 网络控制工具
第一个例子 增加延时 tc qdsic add dev enp0s3 root netem delay 200ms qdisc : queuing discipline, 当内核需要发送包到某个接口时 ...
- shell 实例
转载自:https://github.com/liquanzhou/ops_doc 这里只作为笔记使用,不做他用 shell实例手册 0 说明{ 手册制作: 雪松 更新日期: 2018-09-1 ...
- [转帖]Shell运维手册
shell实例手册 https://github.com/liquanzhou/ops_doc 0 说明{ 手册制作: 雪松 更新日期: 2018-09-11 欢 ...
随机推荐
- Gramar
一.And 并列关系(and) in addition / and / similarly / likewise / as well as / besides / furthermore / also ...
- LAMP整理
LAMP第一部分 查看编译了哪些软件:是编译时自动生成的 Cat /usr/local/apache2/build/config.nice 网站根目录存放处: /usr/local/apache2/h ...
- Thinking in java之正则表达式小例子
public static final String POEM= "Twas brilling, and the slithy toves\n" + "Did gyre ...
- LCD驱动 15-1
app: read() ---------------------------------------------------------------------------------------- ...
- Scss sass
http://www.ruanyifeng.com/blog/2012/06/sass.htmlscss 声明:1,$blue : #1875e7;2,.class1 { border: 1px so ...
- NLTk
1.python的nltk中文使用和学习资料汇总帮你入门提高 http://blog.csdn.net/huyoo/article/details/12188573
- 基于MVC的应用框架之Struts前奏
1.JSP&Servlet中的MVC MVC的关键是,业务逻辑要与表示分离.通过把业务逻辑放在一个“模型”中,这样业务逻辑本身就能作为一个可重用的JAVA类存在. 在JSP&Servl ...
- 【C语言学习】-03 循环结构
本文目录 循环结构的特点 while循环 do...while循环 for循环 回到顶部 一.循环结构的特点 程序的三种结构: 顺序结构:顺序执行语句 分支结构:通过进行一个判断在两个可选的语句序列之 ...
- [Windows驱动]驱动包(Driver Packages)
在windows下安装一个驱动,我们你需要把所有需要的软件打包-称为驱动包.驱动包里包括系统提供的给所有设备类使用的一般安装工具,还包括了设备商提供的设备特定的组件.下面我们就来看看驱动包里具体需要哪 ...
- c++高质量编程手册
怡化主管强烈要求我读这本书.... 笔记尚未完成,持续更新呗.. 第1章 高质量软件开发之道 1.1 软件质量基本概念 1.1.1 如何理解软件的质量:功能性和非公能性 1.1.2 提高软件质量的基本 ...