In general in various metering and policing implementations, burst
size means the granularity of the meter. For example, OpenFlow spec
says:
It defines the granularity of the meter band, for all packet or byte
bursts whose length is greater than burst value, the meter rate will
always be strictly enforced.
https://opennetworking.org/wp-content/uploads/2014/10/openflow-switch-v1.5.1.pdf
Meaning the rate may not be enforced if the traffic burst didn't
exceed the burst size.
Linux traffic policers work the same way (and they are used by OVN, IIUC).
In practice some variation of a token bucket algorithm is used with
the burst size being the size of the bucket, and the rate is the rate of
regeneration of tokens. Algorithms are typically starting with a full
bucket. Meaning that until the initial burst is exhausted, rate limit
is not applied. That matches with your observations.
You may see a following article about choosing the right burst size:
https://www.juniper.net/documentation/us/en/software/junos/routing-policy/topics/concept/policer-mx-m120-m320-burstsize-determining.html
It's about policers, but it's largely applicable to all metering
and policing implementations.
Burst是令牌桶的深度,rate limit是令牌生成的速度。
rate limit越大,令牌生成的速度越快,那么可用的传输速率越快。
但是只要令牌桶里面有令牌,不管当前传输速度是否超过rate limit,都是允许传输的,这就是Burst的功能。
Burst越大,允许的峰值速率越大。
当实际传输速率小于rate limit的时候,新生成的令牌可用存储到桶里面,最多存储Burst指定数量对令牌。
这样,可以实现峰值控制。
OVN里面看起来是实行:Meaning the rate may not be enforced if the traffic burst didn't
exceed the burst size.
从下面看应该所有的burst实现都这样。
A policer burst-size limit controls the number of bytes of traffic that can pass unrestricted through a policed interface when a burst of traffic pushes the average transmit or receive rate above the configured bandwidth limit.