pioc: Pass an IO-command#
xnvme pioc --help
Usage: xnvme pioc <uri> [<args>]
Pass a used-defined IO Command through
Positional arguments:
uri ; Device URI e.g. '/dev/nvme0n1', '0000:01:00.1', '10.9.8.1.8888', '\\.\PhysicalDrive1'
Where <args> include:
[ --cdw0 0xNUM ] ; Command Dword0
[ --cdw1 0xNUM ] ; Command Dword1
[ --cdw2 0xNUM ] ; Command Dword2
[ --cdw3 0xNUM ] ; Command Dword3
[ --cdw4 0xNUM ] ; Command Dword4
[ --cdw4 0xNUM ] ; Command Dword4
[ --cdw5 0xNUM ] ; Command Dword5
[ --cdw6 0xNUM ] ; Command Dword6
[ --cdw7 0xNUM ] ; Command Dword7
[ --cdw8 0xNUM ] ; Command Dword8
[ --cdw9 0xNUM ] ; Command Dword9
[ --cdw10 0xNUM ] ; Command Dword10
[ --cdw11 0xNUM ] ; Command Dword11
[ --cdw12 0xNUM ] ; Command Dword12
[ --cdw13 0xNUM ] ; Command Dword13
[ --cdw14 0xNUM ] ; Command Dword14
[ --cdw15 0xNUM ] ; Command Dword15
[ --opcode 0xNUM ] ; Command opcode
[ --nsid 0xNUM ] ; Namespace Identifier for Command Construction
[ --data-input FILE ] ; Path to data input-file
[ --data-output FILE ] ; Path to data output-file
[ --data-nbytes NUM ] ; Data size in bytes
[ --meta-input FILE ] ; Path to meta input-file
[ --meta-output FILE ] ; Path to meta output-file
[ --meta-nbytes NUM ] ; Meta size in bytes
[ --verbose ] ; Increase output info
With <args> for backend:
[ --subnqn STRING ] ; Subsystem NQN of the NVMe over Fabrics endpoint e.g. 'nqn.2022-06.io.xnvme:ctrlnode1'
[ --hostnqn STRING ] ; The host NQN to use when connecting to NVMe over Fabrics controllers
[ --be STRING ] ; xNVMe backend, e.g. 'linux', 'spdk', 'fbsd', 'macos', 'posix', 'windows'
[ --dev-nsid 0xNUM ] ; Namespace Identifier for Device Handle
[ --admin STRING ] ; xNVMe admin. command-interface, e.g. 'nvme', 'block'
[ --mem STRING ] ; xNVMe buffer/memory manager
[ --direct NUM ] ; Bypass layers
[ --help ] ; Show usage / help
See 'xnvme --help' for other commands
xNVMe - Cross-platform NVMe utility -- ver: {major: 0, minor: 7, patch: 5}
Here is is a usage-example:
# Generate a random input-file
rm -rf /tmp/data-input.bin
dd if=/dev/random of=/tmp/data-input.bin count=1 bs=512
# Use it as payload for a passthru-command (NVM Write)
xnvme pioc /dev/nvme0n1 \
--opcode 0x1 \
--nsid 0x1 \
--data-input /tmp/data-input.bin \
--data-nbytes 512
# Use it as payload for a passthru-command (NVM Read)
xnvme pioc /dev/nvme0n1 \
--opcode 0x2 \
--nsid 0x1 \
--data-output /tmp/data-output.bin \
--data-nbytes 512
# Compare
cmp /tmp/data-input.bin /tmp/data-output.bin