NVME-IO-PASSTHRU(1)
β¨ NVME-IO-PASSTHRU(1) β from the NVMe Manual β¨
hey bestie π this is the NVME-IO-PASSTHRU(1) page from the NVMe Manual, and it's literally the βsubmit an arbitrary io command, return resultsβ page. no cap, it does not interpret your opcodes or options for you β it just sends the command and gives you the results.
π NAME π
nvme-io-passthru β Submit an arbitrary io command, return results.
π¦ SYNOPSIS π¦
nvme [<global-options>] io-passthru <device>
[--opcode=<opcode> | -O <opcode>]
[--flags=<flags> | -f <flags>]
[-rsvd=<rsvd> | -R <rsvd>]
[--namespace-id=<nsid> | -n <nsid>]
[--cdw2=<cdw2> | -2 <cdw2>]
[--cdw3=<cdw3> | -3 <cdw3>]
[--cdw10=<cdw10> | -4 <cdw10>]
[--cdw11=<cdw11> | -5 <cdw11>]
[--cdw12=<cdw12> | -6 <cdw12>]
[--cdw13=<cdw13> | -7 <cdw13>]
[--cdw14=<cdw14> | -8 <cdw14>]
[--cdw15=<cdw15> | -9 <cdw15>]
[--data-len=<data-len> | -l <data-len>]
[--metadata-len=<len> | -m <len>]
[--read | -r] [--write | -w]
[--input-file=<file> | -i <file>]
[--metadata=<file> | -M <file>]
[--show-command | -s]
[--dry-run | -d] [--raw-binary | -b]
[--prefill=<prefill> | -p <prefill>]
[--latency | -T]
π DESCRIPTION π
okay so this submits an arbitrary NVMe IO command and returns the applicable results. That might simply be the commandβs result and status, or it might also include a buffer if the command returns one. Important vibe: this command does no interpretation of the opcodes or options. Itβs giving βraw command energyβ β youβre the main character deciding what goes in.
The <device> parameter is mandatory, bestie. It may be either the NVMe character device (ex: /dev/nvme0), or a namespace block device (ex: /dev/nvme0n1).
On success, the returned structure (if applicable) may be returned in one of several ways depending on the option flags; the structure may be printed by the program as a hex dump, or may be returned as a raw buffer printed to stdout for another program to parse. iconic output flexibility, honestly π
β¨ OPTIONS β¨
-O <opcode>,--opcode=<opcode>β The NVMe opcode to send to the device in the command. Required argument as this param is mandatory β like, non-negotiable, you must give it.-f <flags>,--flags=<flags>β The NVMe command flags to send to the device in the command.-R <rsvd>,--rsvd=<rsvd>β The value for the reserved field in the command.-n <nsid>,--namespace-id=<nsid>β The value for the ns-id in the command. Defaults to0. The broadcast value0xffffffffcan also be given asallor-1.-[2-9] <cdw>,--cdw[2-3,10-15]=<cdw>β Specifies the command dword value for that specified entry in the command. The synopsis lists the individual spellings:-2 <cdw2>/--cdw2=<cdw2>,-3 <cdw3>/--cdw3=<cdw3>,-4 <cdw10>/--cdw10=<cdw10>,-5 <cdw11>/--cdw11=<cdw11>,-6 <cdw12>/--cdw12=<cdw12>,-7 <cdw13>/--cdw13=<cdw13>,-8 <cdw14>/--cdw14=<cdw14>, and-9 <cdw15>/--cdw15=<cdw15>.-r,--read,-w,--writeβ Used for the data-direction for the command and required for commands sending/receiving data. Donβt use both read and write at the same time. fr fr, pick one.-i <file>,--input-file=<file>β If the command is a data-out (write) command, use this file to fill the buffer sent to the device. If no file is given, assumed to use STDIN. If the command is a data-in (read) command, the data returned from the device will be saved here.-M <file>,--metadata=<file>β If the command is a data-out (write) command, use this file to fill the metadata buffer sent to the device. If no file is given, assumed to use STDIN. If the command is a data-in (read) command, the metadata returned from the device will be saved here.-l <data-len>,--data-len=<data-len>β The data length for the buffer used for this command.-m <data-len>,--metadata-len=<data-len>β The metadata length for the buffer used for this command.-s,--show-cmdβ Print out the command to be sent. (the synopsis line also shows--show-command | -s, so keep both spellings in your heart π )-d,--dry-runβ Do not actually send the command. If you want to use--dry-runoption,--show-cmdoption must be set. Otherwise--dry-runoption will be ignored.-b,--raw-binaryβ Print the raw returned buffer to stdout if the command returns data or a structure.-p <prefill>,--prefill <prefill>β Prefill the buffer with a predetermined byte value. Defaults to0. This may be useful if the data you are writing is shorter than the required buffer, and you need to pad it with a known value. It may also be useful if you need to confirm if a device is overwriting a buffer on a data-in command. (the synopsis spells this one--prefill=<prefill> | -p <prefill>β¨)-T,--latencyβ Print out the latency the IOCTL took (in us).
π GLOBAL OPTIONS π
The following options are defined at the top-level nvme command and are available to this subcommand:
--dry-runβ Print the command that would be executed, but do not actually execute it.--no-ioctl-probingβ Disable probing for 64-bit IOCTL support.--no-retriesβ Disable retry logic on transient errors.-o <fmt>,--output-format=<fmt>β Set the reporting format tonormal,tabular,'json, orbinary. Only one output format may be used at a time.--output-format-version=<version>β Select the output format version. Version1uses the original field naming, while version2(default) provides more consistent and script-friendly field names. Other versions are rejected.--quietβ Suppress informational messages. Errors are still reported, and--quietcancels any--verbosefor the library log level.--set-options=<key=value>[,<key=value>...]β Setlibnvmelibrary options for this invocation. Supported keys areforce-4k,mi-probe-enabled,test-base-dirandtest-sysfs-dir.--timeout=<ms>β Set the timeout for the command in milliseconds.infiniteor-1waits without a time limit (0xffffffff).-v,--verboseβ Increase the level of detail in the output. May be specified multiple times to further increase verbosity.
These options can also be set as machine-wide defaults in nvme-cli.conf(5). A command-line flag always overrides the file. periodt, CLI wins π
π EXAMPLES π
nvme io-passthru /dev/nvme0n1 --opcode=2 --namespace-id=1
--data-len=4096 --read --cdw10=0 --cdw11=0 --cdw12=0x70000 --raw-binary
π NVME π
Part of the nvme-user suite.
okay bye bestie π this page is from the NVMe manual, dated 10/30/2026, and it's NVME-IO-PASSTHRU(1) β periodt.
π¦ where this page comes from
- arch rolling: nvme-cli 3.2-1 Β· GPL-2.0-or-later
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms