NVME-ID-NS-GRANUL(1)
π NVME-ID-NS-GRANUL(1) β nvme-id-ns-granularity
okay bestie, welcome to the NVMe Manual β¨ β this one's all about nvme-id-ns-granularity, and it's genuinely so straightforward you're gonna eat it up π
πΈ NAME πΈ
nvme-id-ns-granularity β sends an Identify Namespace Granularity List command to the device you point at π―
π SYNOPSIS π
nvme [<global-options>] id ns-granularity <device>
π¦ DESCRIPTION π¦
So what it does is: it sends a Identify Namespace Granularity List command command to the device you specified, and then it returns the results. That's the whole vibe. No cap. π
The <device> parameter is mandatory β like, you literally cannot skip it, it's giving main character energy and refuses to be optional. And it can be either the NVMe character device (ex: /dev/nvme0) or the block device (ex: /dev/nvme0n1). Either one slays, your choice π«Ά
On success it returns 0. On error, it returns an error code instead. Simple as that, periodt.
okay so this next bit matters β the barenvme id-ns-granularityform (without a space) still works as a deprecated alias, and it will be removed in a future major version. So likeβ¦ it's not dead yet but it's on thin ice π. New scripts should usenvme id ns-granularityinstead. iykyk.
β¨ OPTIONS β¨
π GLOBAL OPTIONS π
These ones are defined at the top-level nvme command and are available to this subcommand too β so they're not even exclusively ours, we're just borrowing them and they're iconic for it π
--dry-runβ prints the command that would be executed, but does not actually execute it. It's the "look but don't touch" of flags π--no-ioctl-probingβ disables probing for 64-bit IOCTL support. Bye probe π--no-retriesβ disables the retry logic on transient errors. One shot, no do-overs π-o <fmt>,--output-format=<fmt>β sets the reporting format tonormal,tabular,json,orbinary. Only one output format may be used at a time β pick a lane bestie π―--output-format-version=<version>β selects the output format version. Version1uses the original field naming, while version2(the default) provides more consistent and script-friendly field names. Any other versions are rejected β not on the list, not invited π«--quietβ suppresses informational messages. Errors are still reported, and--quietcancels any--verbosefor the library log level. Shhh π€«--set-options=<key=value>[,<key=value>...]β sets libnvme library options for this invocation. The supported keys areforce-4k,mi-probe-enabled,test-base-dirandtest-sysfs-dirπ§--timeout=<ms>β sets the timeout for the command in milliseconds.infiniteor-1waits without a time limit (0xffffffff). Time is a construct β³-v,--verboseβ increases the level of detail in the output. May be specified multiple times to further increase verbosity. Stack it like accessories π
Also!! These options can be set as machine-wide defaults in nvme-cli.conf(5). But a command-line flag always overrides the file β CLI stays winning, always π
π₯ EXAMPLES π₯
- Has the program issue a
id-ns-granularityto display structure.
# nvme id ns-granularity /dev/nvme0
π NVME π
Part of the nvme-user suite. You're welcome π
okay that's the whole page, you're officially an expert now, go forth and granularate (?) π β this masterpiece is from the NVMe source, dated 10/30/2026, mwah π
π¦ 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