# man > db5.3_stat(1)

---
type: CommandReference
command: db5.3_stat
mode: man
section: 1
source: man-pages
---

## Quick Reference

- `db5.3_stat -d file [-fN] [-h home] [-P password] [-s database]` — Display statistics for a specific database file
- `db5.3_stat [-cEelmNrtVZ] [-C Aclop] [-h home] [-L A] [-M A] [-R A] [-P password]` — Display environment statistics
- `-c` — Display locking subsystem statistics
- `-e` — Display environment-wide statistics
- `-m` — Display memory pool (cache) statistics
- `-t` — Display transaction subsystem statistics
- `-V` — Display version information

## Name

Display statistics for Berkeley DB environments.

## Synopsis

**db5.3_stat** **-d** file [**-fN**] [**-h** home] [**-P** password] [**-s** database]

**db5.3_stat** [**-cEelmNrtVZ**] [**-C** Aclop] [**-h** home] [**-L** A] [**-M** A] [**-R** A] [**-P** password]

## Options

### General options

- `-h home` — Specify a home directory for the database environment; if not set, the environment variable `DB_HOME` is used.
- `-P password` — Specify an environment password (use with caution due to command-line visibility).
- `-N` — Do not acquire shared environment locks; intended for debugging only.
- `-V` — Display the version of the Berkeley DB software and exit.

### Database file statistics

- `-d file` — Display statistics for the database file `file`.
- `-f` — Display only the unused bytes in the database file.
- `-s database` — Display statistics for the named database within the file specified by `-d`. If omitted, statistics are for the internal database that describes other databases.

### Environment subsystem statistics

- `-c` — Display locking subsystem statistics.
- `-C Aclop` — Display detailed locking subsystem information (debugging output). Suboptions:
  - `A` — All information.
  - `c` — Lock conflict matrix.
  - `l` — Lockers within hash chains.
  - `o` — Lock objects within hash chains.
  - `p` — Locking subsystem parameters.
- `-e` — Display environment-wide statistics (all subsystems).
- `-E` — Display detailed environment-wide statistics (debugging).
- `-l` — Display logging subsystem statistics.
- `-L A` — Display detailed logging subsystem information (debugging). Suboption `A` for all.
- `-m` — Display memory pool (cache) statistics.
- `-M A` — Display detailed memory pool information (debugging). Suboptions:
  - `A` — All.
  - `h` — Buffers within hash chains.
- `-r` — Display replication statistics.
- `-R A` — Display detailed replication information (debugging). Suboption `A` for all.
- `-t` — Display transaction subsystem statistics.
- `-Z` — Clear statistics after displaying (for `-C`, `-c`, `-E`, `-e`, `-L`, `-l`, `-M`, `-m`, `-R`, `-r`, `-t`).

### Output formatting

Values normally in bytes are displayed as GB/MB/KB/B. Values < 10 million are plain numbers; values >= 10 million are shown with "M" suffix.

## Examples

No examples are provided in the original man page.

## Exit Codes

- `0` — Success
- `>0` — Error occurred

## Environment

- `DB_HOME` — If `-h` is not specified, this variable sets the database home directory (as used in `DB_ENV->open`).