I wanted to test how the latency of a packet would be affected by rate limiting the throughput of an interface. I have an interface named veth-red. It will received ICMP packet and routes it to veth-green. The veth-green then responds with the ICMP respone.
I was sending an ICMP packet of 1500 byte and wanted to set the rate on veth-red to be 10000 bits per second, so that I will get the response after 1.2 seconds. I used the following
sudo tc qdisc add dev veth-red root tbf rate 10000bit burst 12kbit latency 5000ms
Unexpectedly, I received the ping response in 0.057 ms. Also as soon as I change the burst to some value under 12kbit, my response is failing. How should I set the rate properly to see my expected behavior.
I have posted this question in the askubuntu forum but did not get any answer or suggestion.