-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathlsnvme.8
187 lines (158 loc) · 4.68 KB
/
lsnvme.8
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
.TH lsnvme 8 "24 AUgust 2015" "lsnvme-0.1"
.IX lsnvme
.SH NAME
lsnvme \- list NVMe controllers, devices, and properties
.SH SYNOPSIS
.B lsnvme
.RB [ options ] [ devices ... ]
.SH DESCRIPTION
.B lsnvme
lsnvme is a utility for displaying devices attached to the NVMe controller(s)
or the controllers themselves and associated info.
With no arguments it shows a list of devices attached to the NVMe controller(s).
Use the options described below to request more verbose output, machine
readable output, or to list the controllers.
When given one or more devices lsnvme will try to detect the device type and
display the appropriate information. The nvme devices may be a block or character
device under /dev or a sysfs directory (ie /sys/class/nvme/nvme1).
.SH OPTIONS
.SS Basic display modes
.TP
.B -m
Display data in a machine readable form.
.TP
.B -t
Show a tree-like diagram containing all buses, bridges, devices and connections
between them.
.TP
.B -H
Display host context.
.SS Display options
.TP
.B -v
In addition to querying udev for basic device info, perform an NVME ID command and
display basic information from it.
.TP
.B -vv
Be very verbose and display more details. This level includes everything deemed
useful.
.TP
.B -vvv
Be even more verbose and display everything we are able to parse,
even if it doesn't look interesting at all (e.g., undefined memory regions).
.TP
.B -k
Show kernel drivers handling each device and also kernel modules capable of handling it.
Turned on by default when
.B -v
is given in the normal mode of output.
(Currently works only on Linux with kernel 2.6 or newer.)
.TP
.B -s [gmkb]
Force dsiplaying sizes in specified format (m == megabyte == 1024 * 1000 * 1000).
.SS Options to control resolving ID's to names
.TP
.B -n
Show PCI vendor and device codes as numbers instead of looking them up in the
PCI ID list.
.TP
.B -nn
Show PCI vendor and device codes as both numbers and names.
.SS Other options
.TP
.B -V
Shows
.I lsnvme
version. This option should be used stand-alone.
.SH MACHINE READABLE OUTPUT
If you intend to process the output of lsnvme automatically, please use one of the
machine-readable output formats
.RB ( -m ,
.BR -vm ,
.BR -vmm )
described in this section. All other formats are likely to change
between versions of nvme.
.P
All numbers are always printed in hexadecimal. If you want to process numeric ID's instead of
names, please add the
.B -n
switch.
.SS Simple format (-m)
In the simple format, each device is described on a single line, which is
formatted as parameters suitable for passing to a shell script, i.e., values
separated by whitespaces, quoted and escaped if necessary.
Some of the arguments are positional: slot, class, vendor name, device name,
subsystem vendor name and subsystem name (the last two are empty if
the device has no subsystem); the remaining arguments are option-like:
.P
The relative order of positional arguments and options is undefined.
New options can be added in future versions, but they will always
have a single argument not separated from the option by any spaces,
so they can be easily ignored if not recognized.
.SS Verbose format (-vmm)
The verbose output is a sequence of records separated by blank lines.
Each record describes a single device by a sequence of lines, each line
containing a single
.RI ` tag :
.IR value '
pair. The
.I tag
and the
.I value
are separated by a single tab character.
Neither the records nor the lines within a record are in any particular order.
Tags are case-sensitive.
.P
The following tags are defined:
.TP
.B Slot
The name of the slot where the device resides
.RI ([ domain :] bus : device . function ).
This tag is always the first in a record.
.TP
.B Class
Name of the class.
.TP
.B Vendor
Name of the vendor.
.TP
.B Device
Name of the device.
.TP
.B SVendor
Name of the subsystem vendor (optional).
.TP
.B SDevice
Name of the subsystem (optional).
.TP
.B PhySlot
The physical slot where the device resides (optional, Linux only).
.TP
.B Rev
Revision number (optional).
.TP
.B ProgIf
Programming interface (optional).
.TP
.B Driver
Kernel driver currently handling the device (optional, Linux only).
.TP
.B Module
Kernel module reporting that it is capable of handling the device
(optional, Linux only).
.P
New tags can be added in future versions, so you should silently ignore any tags you don't recognize.
.SH EXAMPLES
.SH BUGS
NVMe controllers with no attached devices may not show up.
The order that the devices are displayed in is what libudev returns, which may or may not be sorted.
.SH SEE ALSO
.BR lspci (8),
.BR lsscsi (8),
.BR lsblk (8),
.SH AUTHORS
.nf
Patrick McCormick <[email protected]>
Jay Freyensee <[email protected]>
.fi
Modeled after lsscsi, lspci, and lsblk utilities.