Link Utilization Calculator: SNMP Counters and 95th Percentile

This link utilization calculator turns two SNMP octet-counter readings into a percentage of link capacity. It corrects 32-bit and 64-bit counter wraps, treats full-duplex and half-duplex links correctly, warns when your polling interval is too slow for the counter size, and finds the 95th percentile of a list of utilisation samples.

Result

The result updates automatically as you change any input.

Formula and worked steps
Formulas used
  • Delta octets = second reading - first reading (if the second is lower the counter wrapped once: delta = 2^width - first + second)
  • Utilisation % = (delta octets x 8) / (interval seconds x link speed in bits per second) x 100
  • Counter wrap time = 2^width x 8 / link speed
  • Full duplex: in and out are each measured against the full link speed; half duplex: (in + out) shares one link speed
  • 95th percentile = value at rank ceil(0.95 x n) after sorting ascending
Assumptions
  • At most one counter wrap is assumed between two readings; the tool warns when your interval is longer than the wrap time at line rate.
  • Link speed is the nominal speed; on a rate-limited or shaped circuit enter the committed rate, not the port speed.
  • Averages over a polling interval hide bursts shorter than the interval.
References

What is link utilization?

Link utilization is the share of a link’s capacity that carried traffic during a period. Network monitoring does not measure it directly. Instead a poller reads an interface counter, such as ifInOctets, at two moments and divides the difference by what the link could have carried in that time. The result is an average over the polling interval, which is why a five-minute graph can look calm while users still feel congestion during short bursts.

The formula

Utilisation = (Δoctets × 8) ÷ (Δt × link speed) × 100. The factor of 8 turns octets into bits, Δt is the number of seconds between readings, and the link speed is in bits per second. If 375,000,000 octets cross a 100 Mbps link in 60 seconds, the traffic is 3,000,000,000 bits ÷ 60 s = 50 Mbps, which is 50% utilisation.

32-bit and 64-bit counters

A 32-bit counter holds values up to 4,294,967,295 and then wraps to zero. At 1 Gbps that happens every 34.4 seconds, at 100 Mbps every 5.7 minutes and at 10 Mbps every 57 minutes. A 64-bit counter (ifHCInOctets) takes hundreds of years to wrap even at 10 Gbps. RFC 2863 requires 64-bit octet counters on interfaces faster than 20 Mbps, so use them whenever your devices offer them. With 32-bit counters you must poll more often than the wrap time, or a missed wrap makes the result too low.

How the link utilization calculator works

Handling a wrap

If the second reading is lower than the first, the counter wrapped once and the delta is 2^width − first + second. For example, a 32-bit counter that goes from 4,294,000,000 to 100,000,000 moved 967,296 + 100,000,000 = 100,967,296 octets. The tool does this for you and tells you when it happened. It also warns when the interval is longer than the wrap time at line rate, because then more than one wrap could have occurred and the arithmetic cannot detect it.

Full and half duplex

On a full-duplex link each direction has the full speed available, so inbound and outbound are measured separately and the busier one tells you whether the link is near its limit. On a half-duplex link, which is rare today, both directions share one channel, so the tool adds them together before comparing with the speed.

The 95th percentile

Service providers often bill on the 95th percentile of five-minute samples over a month: sort the samples, throw away the top 5%, and bill on the highest remaining value. Paste your samples in Mbps, one per line, and the tool uses the nearest-rank method, the value at rank ceil(0.95 × n). For 20 samples from 10 to 200 Mbps the answer is 190 Mbps, the 19th value. The average of the same list is 105 Mbps and the peak 200 Mbps, which shows why the percentile sits between them.

Worked example

You poll a 1 Gbps trunk every 60 seconds with 32-bit counters and see a wrap. At 1 Gbps the counter wraps in 34.4 seconds, shorter than your interval, so the tool warns. A reading of 100% could be correct, or the counter may have wrapped twice. Switching to 64-bit counters removes the doubt.

Choosing a polling interval

Shorter intervals reveal bursts but create more data and more load on devices. Five minutes is the traditional default and is fine for trend and billing. One minute is better for capacity alerts, and 10 to 30 seconds is useful on links that carry storage or voice traffic, where a congested second matters. Whatever you choose, keep it consistent: percentiles from different resolutions are not comparable, because longer intervals average away the peaks.

Checking a result by hand

Convert both readings to bits, subtract and divide. If the counter moved 1,500,000,000 octets in 300 seconds, that is 12,000,000,000 bits ÷ 300 = 40 Mbps. On a 1 Gbps link that is 4%. If your monitoring shows something very different, look for a wrong ifSpeed, a counter reset after a reboot, or a mix-up between bytes and bits before suspecting the link.

Why it matters for network engineers

Capacity decisions rest on utilisation data, and bad data leads to bad decisions: upgrading a link that was never busy, or ignoring one that was. Knowing how counters behave also helps you spot monitoring artefacts such as sudden spikes after a device reboot, which resets counters to zero, or flat lines on interfaces that report ifSpeed incorrectly. ifSpeed is a 32-bit gauge that tops out at 4,294,967,295 bps, so faster links report through ifHighSpeed in Mbps.

Once you have a trustworthy utilisation figure, you can plan upgrades with the WAN bandwidth calculator and check whether a single TCP flow can fill the pipe with the bandwidth delay product calculator.

Best practices and common mistakes

Alert on sustained utilisation, for example above 70% for 15 minutes, rather than a single sample. Keep the raw counters for at least a few weeks so you can recalculate percentiles at a different resolution. Compare the busiest direction, not the average of both, because congestion happens one direction at a time.

Common errors are using the port speed on a shaped circuit, mixing bits and bytes, and averaging percentages from different links. Another is trusting a five-minute average for voice or storage traffic, where microbursts matter; for those, use a shorter interval or queue-drop counters. After a change of speed, such as a port moved from 1 Gbps to 10 Gbps, update the speed in your monitoring or every percentage will be ten times too high.

When utilisation looks fine but users complain

Low average utilisation does not rule out congestion. Look at output drops and queue depths on the interface, check for microbursts at a shorter polling interval, and consider the path as a whole: an oversubscribed uplink one hop away can be the real limit, which you can quantify with the oversubscription ratio calculator.

FAQs

How do you calculate link utilization from SNMP counters?

Subtract the first octet reading from the second, multiply by 8 to get bits, divide by the seconds between readings multiplied by the link speed in bits per second, then multiply by 100.

How fast does a 32-bit SNMP counter wrap?

At 1 Gbps a 32-bit octet counter wraps in about 34 seconds, at 100 Mbps in about 5.7 minutes and at 10 Mbps in about 57 minutes. Use 64-bit counters on fast links.

What is the 95th percentile of bandwidth?

Sort all samples, discard the highest 5%, and take the highest of the rest. Many providers bill on this value because it ignores short bursts.

Should full-duplex utilisation be added together?

No. Each direction has its own full capacity on a full-duplex link, so measure inbound and outbound separately and look at the higher of the two.

Next, try the bandwidth delay product calculator, the WAN bandwidth calculator and oversubscription ratio calculator, or browse all Bandwidth & Capacity Planning calculators and the full list of network calculators.