wondershaper是一款在Linux內核下基於TC工具的對整塊網卡的限度工具,雖然有好久沒有更新了,可是測試老版本在Centos6.5上依然能夠使用。
在Linux/Centos下
首先下載wondershaper的rpm安裝包:wondershaper-1.1a-7.noarch.rpm
安裝wondershaper:工具
[root@localhost ~]# rpm -ivh wondershaper-1.1a-7.noarch.rpm測試
限速命令:
第一個參數爲網卡接口名,後面兩個數字分別表明下行和上行的速度(單位Kb)接口
[root@localhost ~]# wondershaper eth0 5000 500get
取消限速:it
[root@localhost ~]# wondershaper clear eth0io
在Linux/debian下用wondershaper限速下載
Their suggestion:
apt-get install wondershaper
wondershaper - An easy tool to limit bandwidth of a particular interface.debian
$ sudo wondershaper {interface} {down} {up}
the {down} and {up} are bandwidth in kpbsim
So for example if you want to limit the bandwidth of interface eth1 to 256kbps uplink and 128kbps downlink,ant
$ sudo wondershaper eth1 256 128
To clear the limit,
$ sudo wondershaper clear eth1