nvme-cli 2.11
The management tool for NVMe drives, reading the health log, wear percentage, and error counts, and handling namespace management, secure erase, and firmware operations.
Download TAR.GZ Project website ↗Download Mirrors
NVMe is a different protocol from SATA with its own command set and health reporting. nvme-cli speaks it directly.
The health log
sudo nvme list
sudo nvme smart-log /dev/nvme0
critical_warning : 0
temperature : 41 C
available_spare : 100%
percentage_used : 3%
media_errors : 0
percentage_used is a vendor wear estimate where 100 means rated endurance reached. Drives often continue past it; treat it as a replacement planning signal.
available_spare dropping below its threshold is a genuine warning and one of the better failure predictors.
media_errors should be zero.
critical_warning non-zero means the drive is reporting a specific problem.
Thermal throttling
sudo nvme smart-log /dev/nvme0 | grep -i temp
NVMe drives reduce performance when hot, which is the usual explanation for a drive that starts a large transfer fast and slows partway through. Run a sustained fio job and watch the temperature.
Secure erase
sudo nvme format /dev/nvme0n1 --ses=1 # cryptographic erase
Discards the internal encryption key, making everything unrecoverable in seconds regardless of capacity. This is what to do before selling or returning a drive, and it is dramatically faster than overwriting.
Destructive with no meaningful confirmation. Check the device name twice.
Alongside smartctl
smartmontools reads the same health log in a familiar format and can alert through smartd, which is what you want for routine monitoring.
nvme-cli covers what smartctl does not: namespaces, format and secure erase, firmware slots, and vendor log pages.
A monthly check
for d in /dev/nvme?; do
sudo nvme smart-log "$d" | grep -E 'critical_warning|percentage_used|available_spare|media_errors'
done
Run it from a systemd timer and you will know a drive is wearing out long before it fails. Our nvme-cli guide covers the rest.
Verify Your Download
Source releases are on GitHub.