- Count flows per min during the input
min_threshold is 2000 flows per min.
- If the count is below the min_threshold, work normally
- If the count is above the min_threshold, do sampling like this
- Sample with ratio sr for 1 min duration. (The sample ratio depends on the flows/min value)
Flows/min is fm
sample ratio(fm) = (X^2)/20000
If X = 2000, sr = 200
If X = 3000, sr = 450
If X = 4000, sr = 800
- After 1 minute sampling, we go back to process all flows to count the flows/min again
- Count how many flows/min (only 6 sec, and multiply by 10)
- do again the check
min_threshold is 2000 flows per min.
Flows/min is fm
sample ratio(fm) = (X^2)/20000
If X = 2000, sr = 200
If X = 3000, sr = 450
If X = 4000, sr = 800