pioc: Pass an IO-command#
xnvme pioc --help
Usage: xnvme pioc <uri> [<args>]
Pass a used-defined IO Command through
Where <args> include:
uri ; Device URI e.g. '/dev/nvme0n1', '0000:01:00.1', '10.9.8.1.8888', '\\.\PhysicalDrive1'
[ --nsid 0xNUM ] ; Namespace Identifier for Command Construction
--cmd-input FILE ; Path to command input-file
[ --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
[ --dev-nsid 0xNUM ] ; Namespace Identifier for Device Handle
[ --be STRING ] ; xNVMe backend, e.g. 'linux', 'spdk', 'fbsd', 'posix', 'windows'
[ --admin STRING ] ; xNVMe admin. command-interface, e.g. 'nvme', 'block'
[ --help ] ; Show usage / help
See 'xnvme --help' for other commands
xNVMe - Cross-platform NVMe utility -- ver: {major: 0, minor: 4, patch: 0}
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