LinuxAlternative

Linux · System Tools

nvme-cli

nvme-cli is a command‑line utility for managing NVMe SSDs on Linux.

Open sourceFree
Be the first to rate
License
GPL-2.0
Latest version
3.1

What is nvme-cli?

nvme-cli provides direct access to the NVMe specification, letting you query health data, firmware, namespaces and perform low‑level operations. It has been part of the Linux ecosystem for several years and is maintained in the mainline kernel tree, so it works across most distributions.

The tool is aimed at system administrators, power users and developers who need precise control over NVMe devices, especially in servers or workstations where graphical tools are unavailable. It mirrors many of the diagnostics you get from Windows utilities like CrystalDiskInfo, but everything is done via the terminal.

Compared with CrystalDiskInfo, nvme-cli feels more technical: you type commands and parse output rather than click through a GUI. That can be a drawback for casual users, but it also means you can script checks, integrate with monitoring systems, and avoid the overhead of a graphical interface.

Best for: Sysadmins and power users who need detailed, scriptable control over NVMe SSDs.

Key features of nvme-cli

  • Read SMART health information
  • Display controller and namespace details
  • Update firmware
  • Create, delete, and resize namespaces
  • Perform secure erase and format operations
  • Set and get feature flags
  • Support for NVMe over Fabrics
  • Works on all major Linux distros

Pros

  • Runs on any Linux distro with package support
  • No GUI dependencies, low resource usage
  • Fully scriptable for automation
  • Up‑to‑date with the latest NVMe spec

Cons

  • Steep learning curve for users unfamiliar with CLI
  • No graphical overview; output is raw text
  • Limited to NVMe devices; not useful for SATA drives

Windows programs nvme-cli replaces

How to install nvme-cli on Linux

Ubuntu / Mintsudo apt install nvme-cli
Debiansudo apt install nvme-cli
Fedorasudo dnf install nvme-cli
Arch / Manjarosudo pacman -S nvme-cli
openSUSEsudo zypper install nvme-cli

Tips for Windows users

CrystalDiskInfo presents health metrics in a window; with nvme-cli you’ll use commands like nvme smart-log /dev/nvme0 and parse the fields manually. There are no proprietary file formats to convert—just device nodes. Familiarise yourself with common flags (-o, -s, -f) and consider aliasing frequent commands in your shell for quicker access.

nvme-cli: frequently asked questions

How do I check SSD health with nvme-cli?

Run nvme smart-log /dev/nvme0 (replace the device name) and look at the 'critical_warning' and 'temperature' fields.

Can I update NVMe firmware using nvme-cli?

Yes, use nvme fw-download followed by nvme fw-activate with the appropriate image file.

Is nvme-cli included in the default Ubuntu install?

No, but it is available in the Ubuntu repositories and can be installed with sudo apt install nvme-cli.

Does nvme-cli support NVMe over Fabrics?

Basic NVMe‑of‑Fabrics commands are supported, though advanced management may require additional tools.

Updated