---
name: "cache_metadata_size"
section: "8"
platform: "linux"
package: "thin-provisioning-tools"
version: "1.3.4-1"
release: "Arch Linux 2026-11-01"
platforms: ["linux"]
url: "https://new.carta.tech/cache_metadata_size"
---

# cache\_metadata\_size(8)

Estimate the size of the metadata device needed for a given configuration.

## NAME

**cache\_metadata\_size** - Estimate the size of the metadata device needed for a given configuration.

## SYNOPSIS

```
cache_metadata_size [options]
```

## DESCRIPTION

**cache\_metadata\_size estimates the size of the metadata. Either --nr-blocks,** **or --block-size and --device-size must be specified.**

## OPTIONS

- **--nr-blocks {natural}**

  **Specify the number of cache blocks.**

- **--block-size {sectors}**

  **Specify the size of each cache block in 512 byte sectors.**

- **--device-size {sectors}**

  **Specify total size of the fast device used in the cache.  In 512 byte sectors.**

- **--max-hint-width {nr bytes}**

  **Specify hint width.**

```
    Cache policies use a per block 'hint' to record extra info (for instance
    hit counts).  At the moment all policies use a 4 byte hint
    width.  If you want to use a different hint width specify it with this
    switch.
```

## EXAMPLE

**$ cache\_metadata\_size --nr-blocks 10240**

**$ cache\_metadata\_size --block-size 128 --device-size 1024000**

## SEE ALSO

**[cache\_dump(8)](/cache_dump/8.md), [cache\_repair(8)](/cache_repair/8.md), [cache\_restore(8)](/cache_restore/8.md)**

## AUTHOR

**Joe Thornber \<ejt@redhat.com\>, Heinz Mauelshagen \<heinzm@redhat.com\>**
