> ## Documentation Index
> Fetch the complete documentation index at: https://clickhouse.com/docs/llms.txt
> Use this file to discover all available pages before exploring further.

> Same as `system.jemalloc_bins` but with one row per (arena, bin) instead of aggregating over arenas. Slabs belong to a single arena, so this table locates fragmentation in a specific arena (including the dedicated MergeTree metadata, JIT and cache arenas) and joins to `system.jemalloc_sampled_allocations` on both `arena` and size class.

# system.jemalloc_arena_bins

<h2 id="description">
  Description
</h2>

Same as `system.jemalloc_bins` but with one row per (arena, bin) instead of aggregating over arenas. Slabs belong to a single arena, so this table locates fragmentation in a specific arena (including the dedicated MergeTree metadata, JIT and cache arenas) and joins to `system.jemalloc_sampled_allocations` on both `arena` and size class.

<h2 id="columns">
  Columns
</h2>

* `arena` ([UInt32](/docs/reference/data-types/int-uint)) — Index of the arena. Joins to `system.jemalloc_sampled_allocations.arena`.
* `purpose` ([String](/docs/reference/data-types/string)) — Purpose of a dedicated long-lived arena: 'mergetree' (part and table metadata), 'jit', 'cache'. Empty for general-purpose arenas. Dedicated arenas hold long-lived allocations by design; fragmentation reports usually exclude them.
* `index` ([UInt16](/docs/reference/data-types/int-uint)) — Index of the bin ordered by size.
* `large` ([UInt8](/docs/reference/data-types/int-uint)) — True for large allocations and False for small.
* `size` ([UInt64](/docs/reference/data-types/int-uint)) — Size of allocations in this bin.
* `allocations` ([Int64](/docs/reference/data-types/int-uint)) — Number of allocations.
* `deallocations` ([Int64](/docs/reference/data-types/int-uint)) — Number of deallocations.
* `nregs` ([Int64](/docs/reference/data-types/int-uint)) — Number of regions per slab.
* `curslabs` ([Int64](/docs/reference/data-types/int-uint)) — Current number of slabs.
* `curregs` ([Int64](/docs/reference/data-types/int-uint)) — Current number of regions for this size class.
* `slab_size` ([UInt64](/docs/reference/data-types/int-uint)) — Size of each slab in bytes. Zero for large size classes, which are not slab-based.
* `nonfull_slabs` ([Int64](/docs/reference/data-types/int-uint)) — Current number of slabs that contain at least one free region. Zero for large size classes.

**Aliases:**

* `availregs` — Alias for `nregs * curslabs`.
* `util` — Alias for `curregs / availregs`.
* `waste` — Alias for `greatest((curslabs * slab_size) - (curregs * size), 0)`.
