---
type: Article
title: "SNMP Storage Calculator | hrStorage MIB"
description: "Calculate disk or memory capacity from Host Resources MIB allocation units, size, and used values. Get bytes and utilization."
resource: "https://snmp-monitoring.com/tools/snmp-storage-calculator/"
tags: [tools, snmp]
timestamp: 2026-07-13T00:00:00Z
---

# SNMP Storage Calculator

Convert Host Resources MIB storage readings into bytes, capacity, free space, and utilization. Enter the allocation-unit size, total units, and used units from the same `hrStorageTable` row. This avoids treating `hrStorageSize` or `hrStorageUsed` as byte counts when the agent reports them in allocation units.

## Host Resources MIB storage formula

The `hrStorageTable` describes logical storage areas. `hrStorageAllocationUnits` gives the number of bytes represented by each unit. Multiply it by `hrStorageSize` for total capacity and by `hrStorageUsed` for used capacity. Subtract used from total to estimate free space. Divide used units by total units and multiply by 100 for utilization.

`capacity bytes = allocation units × hrStorageSize`

`used bytes = allocation units × hrStorageUsed`

For example, if the allocation unit is 4096 bytes and the row has 262,144 total units with 187,500 used, capacity is 1 GiB and usage is about 732.4 MiB. Keep all three values from one row because allocation sizes can differ across storage entries.

## Identify the right storage row

`hrStorageDescr` labels rows such as physical memory, virtual memory, or a mounted filesystem. The final OID subidentifier is the row index. Inspect descriptions before comparing values, since an agent can expose multiple filesystems and memory pools. Some devices report a high allocation-unit size to keep 32-bit counters useful for large storage volumes.

The calculator reports binary GiB and MiB conversions. Operating systems and vendor interfaces may display decimal GB instead, where one GB is 1,000,000,000 bytes. This difference can make two accurate displays appear inconsistent. Read the MIB and device documentation when a row's meaning is unclear.

## FAQ

**Are hrStorageSize and hrStorageUsed values bytes?** Usually they are counts of allocation units. Multiply each value by `hrStorageAllocationUnits` to convert it to bytes.

**Why are there several storage rows?** The table can include filesystems, physical memory, virtual memory, and other logical storage areas. Use `hrStorageDescr` and calculate each row independently.

**Why does the result differ from the operating system?** Rounding, reserved blocks, filesystem accounting, update timing, and decimal-versus-binary units can produce differences.

## Conclusion

Use the allocation-unit size from the same row as the total and used values. For related identifiers, browse the [storage OID catalog](/sensors/storage/index.md) and use the [SNMP walk decoder](/tools/snmp-walk-decoder.md) to inspect a device response.
