Change congestion control algorithm in Linux
1.查看可用的TCP version
ls /lib/modules/`uname -r`/kernel/net/ipv4/ (我電腦uname -r 是 3.13.0-32-generic)
會跑出類似的東西
2.查看現在跑的TCP versionip_gre.ko netfilter tcp_cubic.ko tcp_htcp.ko tcp_lp.ko tcp_vegas.ko ipip.ko tcp_bic.ko tcp_highspeed.ko tcp_hybla.ko tcp_scalable.ko tcp_veno.ko
3.更改Linux預設的TCP version (關鍵字為:Congestion Control Algorithms) (記得到root sudo -s)cat /proc/sys/net/ipv4/tcp_congestion_control
echo "westwood" > /proc/sys/net/ipv4/tcp_congestion_control
4.觀察TCP version 的差異
a.安裝 netperf (serve/client 都要安裝喔)
到這個網站下載 ftp://ftp.netperf.org/netperf/
解壓縮他 tar zxvf netperf-2.6.0.tar.gz
CD到資料夾 cd netperf-2.6.0
輸入指令 ./configure
輸入指令 make
輸入指令 make install
b.server 端指令
[root@server2 opt]#netserver
Starting netserver at port 12865
Starting netserver at hostname 0.0.0.0 port 12865 and family AF_UNSPEC
c.client 端指令
[root@server1 etc]# netperf -H 10.10.10.131 -l 60 -t TCP_STREAM
-H :host namae
-l :test time
-t :test servise
參考網站
1.How to run Different congestion control algorithms in FEDORA 17 ..?
http://unix.stackexchange.com/questions/69241/how-to-run-different-congestion-control-algorithms-in-fedora-17
2.Controlling which congestion control algorithm is used in Linux
http://sgros.blogspot.tw/2012/12/controlling-which-congestion-control.html
3.RPM resource kmod(tcp_veno.ko)
http://www.rpmfind.net/linux/rpm2html/search.php?query=kmod(tcp_veno.ko)
4.Why there's no tcp_westwood?
http://askubuntu.com/questions/393853/why-theres-no-tcp-westwood
5.實體書本Linux Kernel Module 及TCP/IP程序设计
6.TCP and Linux' Pluggable Congestion Control Algorithms***
http://linuxgazette.net/135/pfeiffer.html
7.測試工具netperf
http://www.cnblogs.com/mayingbao/p/3198629.html
http://www.51testing.com/html/92/422092-241001.html
http://gaizaoren.blog.51cto.com/622250/184889
http://wolfbeing.blog.51cto.com/435511/190470
http://www.ibm.com/developerworks/cn/linux/l-netperf/
6.TCP and Linux' Pluggable Congestion Control Algorithms***
http://linuxgazette.net/135/pfeiffer.html
7.測試工具netperf
http://www.cnblogs.com/mayingbao/p/3198629.html
http://www.51testing.com/html/92/422092-241001.html
http://gaizaoren.blog.51cto.com/622250/184889
http://wolfbeing.blog.51cto.com/435511/190470
http://www.ibm.com/developerworks/cn/linux/l-netperf/
留言
張貼留言