Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- # define latency groups
- tc qdisc add dev bond0.110 root handle 1: htb
- tc class add dev bond0.110 parent 1: classid 1:1 htb rate 10gbit
- tc class add dev bond0.110 parent 1:1 classid 1:11 htb rate 10gbit
- # define latency in groups
- tc qdisc add dev bond0.110 parent 1:11 handle 10: netem delay 0ms 0ms 25%
- tc qdisc add dev bond0.110 parent 1:12 handle 10: netem delay 5ms 0ms 25%
- tc qdisc add dev bond0.110 parent 1:13 handle 10: netem delay 10ms 0ms 25%
- # first datacenter
- tc filter add dev bond0.110 protocol ip u32 match ip dst 172.19.10.30 flowid 1:11
- tc filter add dev bond0.110 protocol ip u32 match ip dst 172.19.10.40 flowid 1:11
- tc filter add dev bond0.110 protocol ip u32 match ip dst 172.19.10.42 flowid 1:11
- tc filter add dev bond0.110 protocol ip u32 match ip dst 172.19.10.100 flowid 1:11
- tc filter add dev bond0.110 protocol ip u32 match ip dst 172.19.10.103 flowid 1:11
- tc filter add dev bond0.110 protocol ip u32 match ip dst 172.19.10.106 flowid 1:11
- # second datacenter
- tc filter add dev bond0.110 protocol ip u32 match ip dst 172.19.10.31 flowid 1:12
- tc filter add dev bond0.110 protocol ip u32 match ip dst 172.19.10.41 flowid 1:12
- tc filter add dev bond0.110 protocol ip u32 match ip dst 172.19.10.43 flowid 1:12
- tc filter add dev bond0.110 protocol ip u32 match ip dst 172.19.10.101 flowid 1:12
- tc filter add dev bond0.110 protocol ip u32 match ip dst 172.19.10.104 flowid 1:12
- # third datacenter
- tc filter add dev bond0.110 protocol ip u32 match ip dst 172.19.10.32 flowid 1:13
- tc filter add dev bond0.110 protocol ip u32 match ip dst 172.19.10.44 flowid 1:13
- tc filter add dev bond0.110 protocol ip u32 match ip dst 172.19.10.102 flowid 1:13
- tc filter add dev bond0.110 protocol ip u32 match ip dst 172.19.10.105 flowid 1:13
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement