Repository navigation
Breaking changes
This page lists the changes in each nvme-cli 3.x release that can break a script, a configuration, a build or a program that uses libnvme. New features and bug fixes are not listed here. The full list of changes is in NEWS.md.
Read the sections of every release between your old and your new version.
Released 2026-10-30.
nvme-cli parses its command line itself now. Before, it used getopt. The rules are stricter:
- Long options need two dashes and the full name. Abbreviations are an
error, for example
--namespacefor--namespace-id. - A single dash always starts short options.
-verboseis read as-v -e -r -b -o -s -e. - An option with an optional value needs the value attached:
--persistent=forceor-pforce.--persistent forceis an error now. Before, it connected inautomode and droppedforcewithout a message. - An extra operand is an error. A command that takes a device fails without one. Before, extra operands were ignored.
- Every command checks
--output-format. An invalid value is an error, also for commands that do not print anything.
Options and operands can still be given in any order.
Numbers are parsed strictly, on the command line and in nvme-cli.conf:
- Text after the number is an error. Before, it was ignored:
--timeout=10sset a timeout of 10 milliseconds. - A leading zero, a
+and leading spaces are errors. Before, a leading zero made the number octal:--namespace-id=010was namespace 8. Write10, or0x10for hexadecimal.0itself is fine. - An unsigned option rejects a negative number. Before,
-1wrapped around to the largest value. Use the names for the special values instead:allfor a namespace ID of 0xffffffff,infinitefor--timeout.-1is still accepted for these two. - A signed option rejects a value out of its range.
- Sizes with a suffix use a
.as the decimal point in every locale.1.500kis 1500 now. Before, it was 1000.
Some option values have a fixed range now:
-
--selofget-feature, thefeatcommands and theocpandshannonget-feature commands accepts 0 to 3, orcurrent,default,savedandsupported. -
--output-format-versionaccepts only 1 and 2. - Options that take one of a few words reject other words before the device
is opened. Examples are
show-topology --rankingandocp internal-log --telemetry-type. -
lm migration-recvrequires--sel.
Global options mean the same for every command:
- Some commands had their own
--human-readable(-H) or--verbose(-V). These are gone. Use the global--verbose(-v).-Vis an error for these commands. - Some options lost their short name, because a global option uses it. For
example,
config convert --outputhas no-oany more. -
--human-readableand-Hprint a deprecation warning. Use--verbose.
See NEWS.md for the full list of options.
-
nvme <command> --helpprints to stdout and exits with 0. Before, it printed to stderr and exited with 1. - A usage error prints the error, the synopsis and a pointer to the help. Before, it printed the whole help.
- Error messages start with the command name, for example
id ns: /dev/nvme0: Permission denied. - On a terminal, the command name of an error is red. Set
NO_COLORto a non-empty value to turn colors off. -
nvme helpdoes not list the deprecated commands any more. They still work, with a warning.
- The normal (not JSON) output of
id-ctrl,id-nsand most other identify, log page and feature commands uses a table with computed column widths. The field names and values are the same. The spacing is different. Use-o jsonin scripts. The JSON output did not change. - The JSON output of
show-regs,get-regandget-propertyhas one form:{"cc": 4587521}. The values are unsigned. With-v, each register is an object of its value and its fields. -
show-regs,get-regandget-property -vdecode the register fields with the names of the specification.CAP.CSS,CAP.AMS,CAP.CRMSandVSare split into their fields.show-regsnames the Version registervsinstead ofversion. - The JSON output of
log reachability-groupsandreachability-associationslists the IDs of a descriptor in an array. - The JSON output of
wdc vs-smart-add-logprints the C1 performance statistics as 64 bit values.
-
--persistentofdiscover,connect-allandconfig create --discoverydefaults toauto. Before, the default wasno. A Discovery Controller now stays connected when the target reports EPCSD. Use--persistent=nofor the old behavior. See NVMe-oF Persistent Discovery Controllers. -
nvme connectover TCP without--nr-io-queuesuses one I/O queue per queue of the network interface, at most one per online CPU. -
nvme set-reguses a Property Set only for a fabrics controller. It refuses a register the host may not write. -
--dry-runalso skips resets, namespace rescans, thesedoperations that change the drive, and fabrics connects and disconnects. -
nvme copysends the Expected Logical Block Tags and Application Tags in little endian again, as in 2.x. 3.0 and 3.1 sent them in big endian. See issue #4278. - The ScaleFlux plugin does not support the proprietary ScaleFlux kernel driver any more. The clean card feature is removed.
- The deprecated
tls-keycommand no longer accepts abbreviated options.tls-key,gen-dhchap-keyandcheck-dhchap-keyreject extra operands.
- nvme-discoverd is built by default when libsystemd 253 or later is
available. The legacy udev/systemd autoconnect is then not built, and its
files are not installed. Build with
-Dnvme-discoverd=disabledto keep the old behavior. See How to set up NVMe-oF autoconnect. -
meson installinstallsnvme-discoverd.conf.sampleinstead ofnvme-discoverd.conf. Your settings are no longer overwritten. -
epcsd-poll-interval-minutes,fc-kickstart-interval-minutesanddc-giveup-timeoutmoved from[Global]to[Discovery]innvme-discoverd.conf. In[Global], they are ignored with a warning. See nvme-discoverd.
- The
docs-buildoption is removed. Remove-Ddocs-build=truefrom your meson arguments, because meson rejects an unknown option.-Ddocsinstalls the man pages that are in the source tree. Theupdate-docstarget regenerates them. - The WDC, SanDisk, Micron, Samsung and Solidigm plugins use libarchive to
create log archives. They do not call
tarorzipany more. Without libarchive, these subcommands fail with an error.
- The Identify Controller bit field constants for OAES, BPCAP, MEC, OACS,
FRMW, LPA and AVSCC use the names of the NVM Express Base Specification
2.4. The old names are removed. For example,
NVME_CTRL_OACS_FORMATis nowNVME_CTRL_OACS_FNVMS. NEWS.md has the full list. -
libnvme3.pcreports the nvme-cli release version, for example 3.2. Before, it reported 1.0.0. The sonamelibnvme3.so.1did not change.
Released 2026-09-18.
-
nvme gen-hostnqnmust run as root. Without root, it cannot read the DMI and device tree files, and it returned a random identifier before.
- meson 1.0.0 or later is required. Before, 0.62.0 was enough.
- Building the man pages requires
xmlto. -
-Ddocs=manand-Ddocs=allinstall the man pages from the source tree, unless-Ddocs-build=trueis given. 3.2 removesdocs-buildagain.
-
NVME_CAP_NSSRC()is renamed toNVME_CAP_NSSRS(), the name in the specification. -
libnvmf_generate_hostid()uses the machine ID when DMI and the device tree do not give a host ID. Before, it used a random UUID. The machine ID itself is not published.
Released 2026-09-07.
nvme-cli 3.0 has many breaking changes. Migrating from nvme-cli 2.x to 3.0 describes them. In short:
- Many top-level commands moved into plugins. For example,
nvme smart-logis nownvme log smartandnvme id-ctrlis nownvme id ctrl. The old commands still work, with a warning. They are removed in the next major version.-Ddeprecated-cmds=disabledremoves them at build time. -
nvme rpmb --cmd=<action>is nownvme rpmb <action>. The old form does not work any more. - The key commands moved into the
nvme keysplugin. DH-HMAC-CHAP is now called KX-HMAC-CHAP. The output of several key commands changed. -
nvme-fabrics.confreplacesconfig.jsonanddiscovery.conf. The first command that reads the configuration, for examplenvme connect-allwithout options, converts an old file.nvme config convertdoes it explicitly. -
nvme disconnect-alldisconnects only controllers without an owner in the ownership registry. -
nvme ns create,delete,attachanddetachprint nothing on success. Use-vto get the old output. -
nvme resv reportuses the names of the NVM Express Base Specification 2.4:regctlis nowregstrntin the output and in the JSON keys. - The default JSON output format version is 2. In 2.x, it was 1. This
changes
nvme list -v -o json: each namespace lists its paths, instead of each controller listing its namespaces. Use--output-format-version=1for the old layout. See Using nvme-cli in scripts. -
--dump-configis removed fromconnect,discoverandconnect-all. - The
pdc-enabledbuild option is removed. Use--persistentorpersistent =innvme-fabrics.conf. - A C11 compiler is required.
- libnvme is renamed to libnvme3, and libnvme-mi is part of it. The API changed in many places.
Getting Started
Connecting to NVMe-oF Targets
- How to connect to a target
- How to connect to a target over Fibre Channel
- How to configure NVMe-oF connections (nvme-fabrics.conf)
- Using
--host-traddrand--host-iface - How to set up inband authentication
- How to set up TLS for NVMe-TCP
- How to set up NVMe-oF autoconnect
- NVMe-oF Persistent Discovery Controllers (PDC)
- NVMe-oF Multipath and ANA
- nvme-discoverd
- Ownership registry and exclusion list
- Booting from NVMe-oF with NBFT
Security & Encryption
- The
nvme keysPlugin - How to securely erase an NVMe device
- TCG Opal with nvme-cli and cryptsetup
- nvme-keysd
- Privilege Separation
Monitoring
Reference
Contributing / Development