NAME
nvmecontrol
—
NVM Express control utility
SYNOPSIS
nvmecontrol |
devlist |
nvmecontrol |
identify [-v ]
[-x ] ⟨device id⟩ ⟨namespace
id⟩ |
nvmecontrol |
perftest ⟨-n
num_threads⟩
⟨-o
read|write⟩ [-p ]
⟨-s
size_in_bytes⟩
⟨-t
time_in_sec⟩ ⟨namespace
id⟩ |
nvmecontrol |
reset ⟨controller id⟩ |
nvmecontrol |
logpage ⟨-p
page_id⟩ [-x ]
[-v vendor-string]
[-b ] ⟨device id⟩ ⟨namespace
id⟩ |
nvmecontrol |
firmware [-s
slot] [-f
path_to_firmware] [-a ]
⟨device id⟩ |
nvmecontrol |
format [-f
fmt] [-m
mset] [-o
pi] [-l
pil] [-E ]
[-C ] ⟨device id⟩ ⟨namespace
id⟩ |
nvmecontrol |
power [-l ]
[-p -power_state ]
[-w -workload_hint ] |
nvmecontrol |
wdc cap-diag [-o
-path_template ] ⟨device id⟩ |
nvmecontrol |
wdc drive-log [-o
-path_template ] ⟨device id⟩ |
nvmecontrol |
wdc get-crash-dump [-o
-path_template ] ⟨device id⟩ |
DESCRIPTION
NVM Express (NVMe) is a storage protocol standard, for SSDs and other high-speed storage devices over PCI Express.logpage
The logpage command knows how to print log pages of various types. It also knows about vendor specific log pages from hgst/wdc and intel. Page 0xc1 for hgst/wdc contains the advanced smart information about the drive. Page 0xc1 is read latency stats for intel. Page 0xc2 is write latency stats for intel. Page 0xc5 is temperature stats for intel. Page 0xca is advanced smart information for intel.
Specifying -p
help
will list all valid vendors and pages. -x
will print
the page as hex. -b
will print the binary data for
the page.
format
Format either specified namespace, or all namespaces of specified
controller, using specified parameters: fmt LBA
Format, mset Metadata Settings,
pi Protection Information, pil
Protection Information Location. When formatting specific namespace,
existing values are used as defaults. When formatting all namespaces, all
parameters should be specified. Some controllers may not support formatting
or erasing specific or all namespaces. Option -E
enables User Data Erase during format. Option -C
enables Cryptographic Erase during format.
wdc
The various wdc command retrieve log data from the wdc/hgst
drives. The -o
flag specifies a path template to use
to output the files. Each file takes the path template (which defaults to
nothing), appends the drive's serial number and the type of dump it is
followed by .bin. These logs must be sent to the vendor for analysis. This
tool only provides a way to extract them.
EXAMPLES
nvmecontrol devlist
Display a list of NVMe controllers and namespaces along with their device nodes.
nvmecontrol identify
nvme0
Display a human-readable summary of the nvme0 IDENTIFY_CONTROLLER data.
nvmecontrol identify -x -v
nvme0ns1
Display an hexadecimal dump of the nvme0 IDENTIFY_NAMESPACE data for namespace 1.
nvmecontrol perftest -n 32 -o read -s
512 -t 30 nvme0ns1
Run a performance test on nvme0ns1 using 32 kernel threads for 30 seconds. Each thread will issue a single 512 byte read command. Results are printed to stdout when 30 seconds expires.
nvmecontrol reset nvme0
Perform a controller-level reset of the nvme0 controller.
nvmecontrol logpage -p 1
nvme0
Display a human-readable summary of the nvme0 controller's Error Information Log. Log pages defined by the NVMe specification include Error Information Log (ID=1), SMART/Health Information Log (ID=2), and Firmware Slot Log (ID=3).
nvmecontrol logpage -p 0xc1 -v wdc
nvme0
Display a human-readable summary of the nvme0's wdc-specific advanced SMART data.
nvmecontrol logpage -p 1 -x
nvme0
Display a hexadecimal dump of the nvme0 controller's Error Information Log.
nvmecontrol logpage -p 0xcb -b nvme0
> /tmp/page-cb.bin
Print the contents of vendor specific page 0xcb as binary data on standard out. Redirect it to a temporary file.
nvmecontrol firmware -s 2 -f
/tmp/nvme_firmware nvme0
Download the firmware image contained in "/tmp/nvme_firmware" to slot 2 of the nvme0 controller, but do not activate the image.
nvmecontrol firmware -s 4 -a
nvme0
Activate the firmware in slot 4 of the nvme0 controller on the next reset.
nvmecontrol firmware -s 7 -f
/tmp/nvme_firmware -a nvme0
Download the firmware image contained in "/tmp/nvme_firmware" to slot 7 of the nvme0 controller and activate it on the next reset.
nvmecontrol power -l
nvme0
List all the current power modes.
nvmecontrol power -p 3
nvme0
Set the current power mode.
nvmecontrol power nvme0
Get the current power mode.
HISTORY
The nvmecontrol
utility appeared in
FreeBSD 9.2.
AUTHORS
nvmecontrol
was developed by Intel and
originally written by Jim Harris
<jimharris@FreeBSD.org>.
This man page was written by Jim Harris <jimharris@FreeBSD.org>.