Skip to content
ENExplore Calculators

Buffer Size Calculator

Size switch or router buffers using the BDP rule or the Stanford BDP over root-N rule for many flows.

About Buffer Size Calculator

One flow needs a full BDP of buffer to keep the link busy through its sawtooth. With many independent flows the sawtooths desynchronise and their aggregate is far smoother, so the buffer requirement falls by the square root of the flow count. This is why datacentre switches ship with shallow buffers and still run at line rate: with hundreds of flows per port, buffer memory sized to a full BDP would only add latency.

Formula

Buffer Size

buffer = BDP for a single flow, or BDP ÷ √N when N long-lived flows share the link.

BDP
Bandwidth × RTT ÷ 8, in bytes
N
Number of concurrent long-lived TCP flows
√N
Desynchronisation factor from the Stanford buffer-sizing result

Worked example

With the default values below, Buffer Size Calculator returns Recommended Buffer of 4 MiB. Change any input above and every figure here is recalculated in your browser.

Inputs used

Link speedminimum 0.001 Gbit/s
10 Gbit/s
Round-trip timeminimum 0.1 ms
30 ms
Concurrent long-lived TCP flowsminimum 1 flows
100 flows
Use the BDP ÷ √N rule
Yes

Results

Recommended Buffer
4 MiB
Full BDP Rule
36 MiB
BDP ÷ √N Rule
4 MiB
Buffer Drain Time
3.00 ms
Recommended Buffer
3.58 MB

Step by step

  1. 1Values used
  2. 2Buffer Size
  3. 3Recommended Buffer= 3,750,000
  4. 4Full BDP Rule= 37,500,000
  5. 5BDP ÷ √N Rule= 3,750,000
  6. 6Buffer Drain Time= 3.00 ms
  7. 7Recommended Buffer= 3.58 MB

Assumptions and limits

  • The result is derived only from the 4 inputs listed above. Anything not among them is not part of the calculation.
  • In particular, this calculator does not take inflation, tax, fees or charges or compounding frequency into account.
  • Figures are rounded for display to 2 decimal places, so totals built from several rounded parts can differ slightly from the unrounded arithmetic.

How these calculators are built and tested is described on the Methodology page. If a figure looks wrong, please report it.

Frequently Asked Questions

How is Buffer Size calculated?

buffer = BDP for a single flow, or BDP ÷ √N when N long-lived flows share the link. One flow needs a full BDP of buffer to keep the link busy through its sawtooth. With many independent flows the sawtooths desynchronise and their aggregate is far smoother, so the buffer requirement falls by the square root of the flow count.

Why does Buffer Size matter?

This is why datacentre switches ship with shallow buffers and still run at line rate: with hundreds of flows per port, buffer memory sized to a full BDP would only add latency.

What values do I need to enter?

This calculator takes 4 inputs: Link speed, Round-trip time, Concurrent long-lived TCP flows, Use the BDP ÷ √N rule. The pre-filled defaults are a realistic starting point — replace them with figures from your own environment for a result you can act on.

When should I use the full BDP rule instead?

Use the full BDP when a small number of high-rate flows dominate the link — bulk replication, backup windows or a single large file transfer. The √N reduction relies on many independent flows whose congestion cycles do not line up.

Buffer Size Calculator | Calcrivo