I am currently experiencing a problem with the threshold for TCP communications. I use the same script described in this article:
https://blog.sflow.com/2016/05/mininet-flow-analytics.html with 10Mbits as threshold (so 1.25MBytes). For the tests, I use iperf3. With UDP, I have no problem, the event linked with the threshold is correctly triggered when a communication exceeds the limit. But with TCP it is more tricky as sometimes, even with a bandwidth inferior to the limit, the flow is captured. For example: 'iperf3 -c <ip> -p <port> -b 800K -t 12' can trigger the event.
Is there a margin of error in the implementation of the threshold to be careful with? I have done many tests with even a 50Mb threshold but the problem still occurs.
Thank you for your help.