From e2abea9f32a95be38fe2178befaf7c0ce7083c48 Mon Sep 17 00:00:00 2001 From: Michael Vrable Date: Wed, 16 Mar 2011 21:54:37 -0700 Subject: [PATCH] Add notes on using a traffic limiter for benchmarks --- traffic-limiter.txt | 12 ++++++++++++ 1 file changed, 12 insertions(+) create mode 100644 traffic-limiter.txt diff --git a/traffic-limiter.txt b/traffic-limiter.txt new file mode 100644 index 0000000..6b1b24d --- /dev/null +++ b/traffic-limiter.txt @@ -0,0 +1,12 @@ +# Limiting traffic rate to 1mbit to Amazon US-West data center (204.246.0.0/16) +tc qdisc add dev eth0 root handle 1: cbq avpkt 1000 bandwidth 1000mbit +tc class add dev eth0 parent 1: classid 1:1 cbq rate 1mbit allot 1500 prio 5 bounded isolated +tc filter add dev eth0 parent 1: protocol ip prio 16 u32 match ip dst 204.246.0.0/16 flowid 1:1 + +# List traffic classifier state +tc qdisc show dev eth0 +tc class show dev eth0 +tc filter show dev eth0 + +# To clear +tc qdisc del dev eth0 root -- 2.20.1