/ src / lshw.sgml
lshw.sgml
  1  <!DOCTYPE RefEntry PUBLIC "-//OASIS//DTD DocBook V4.1//EN">
  2  <refentry id="lshw">
  3  
  4  <refmeta>
  5  <refentrytitle>lshw</refentrytitle>
  6  <manvolnum>1</manvolnum>
  7  <refmiscinfo>$Rev$</refmiscinfo>
  8  </refmeta>
  9  
 10  <refnamediv>
 11  <refname>lshw</refname>
 12  <refpurpose>
 13  list hardware
 14  </refpurpose>
 15  </refnamediv>
 16  
 17  <refsynopsisdiv>
 18   <cmdsynopsis>
 19     <command>lshw</command> 
 20          <arg choice="opt"><option>-version</option></arg>
 21     </cmdsynopsis>
 22   <cmdsynopsis>
 23     <command>lshw</command> 
 24          <arg choice="opt"><option>-help</option></arg>
 25     </cmdsynopsis>
 26   <cmdsynopsis>
 27     <command>lshw</command> 
 28          <arg choice="opt"><option>-X</option></arg>
 29     </cmdsynopsis>
 30   <cmdsynopsis>
 31     <command>lshw</command> 
 32        <group choice="opt">
 33  	<arg choice="opt"><option>-html</option></arg>
 34  	<arg choice="opt"><option>-short</option></arg>
 35  	<arg choice="opt"><option>-xml</option></arg>
 36  	<arg choice="opt"><option>-json</option></arg>
 37  	<arg choice="opt"><option>-businfo</option></arg>
 38        </group>
 39  	<arg choice="opt"><option>-dump </option><replaceable class="parameter">filename</replaceable></arg>
 40  	<arg choice="opt" rep="repeat"><option>-class </option><replaceable class="parameter">class</replaceable></arg>
 41  	<arg choice="opt" rep="repeat"><option>-disable </option><replaceable class="parameter">test</replaceable></arg>
 42  	<arg choice="opt" rep="repeat"><option>-enable </option><replaceable class="parameter">test</replaceable></arg>
 43  	<arg choice="opt"><option>-sanitize</option></arg>
 44  	<arg choice="opt"><option>-numeric</option></arg>
 45  	<arg choice="opt"><option>-quiet</option></arg>
 46  	<arg choice="opt"><option>-notime</option></arg>
 47     </cmdsynopsis>
 48  </refsynopsisdiv>
 49  
 50  <refsect1><title>DESCRIPTION</title>
 51  <para>
 52  <indexterm><primary>lshw</primary></indexterm>
 53  <application>lshw</application>
 54  is a small tool to extract detailed information on the hardware
 55  configuration of the machine. It can report exact memory
 56  configuration, firmware version, mainboard configuration, 
 57  <hardware>CPU</hardware> version
 58  and speed, cache configuration, bus speed, etc. on 
 59  <acronym>DMI</acronym>-capable x86 or IA-64
 60  systems and on some <productname>PowerPC</productname>
 61  machines (<productname>PowerMac G4</productname> is known to work).
 62  </para>
 63  <para>
 64  It currently supports <hardware>DMI</hardware> (x86 and IA-64 only), <productname>OpenFirmware</productname> device tree (<productname>PowerPC</productname> only),
 65  <hardware>PCI/AGP</hardware>, <hardware>CPUID</hardware> (x86), <hardware>IDE/ATA/ATAPI</hardware>, <hardware>PCMCIA</hardware> (only tested on x86), <hardware>SCSI</hardware> and <hardware>USB</hardware>.
 66  </para>
 67  
 68  <para>
 69  <variablelist>
 70  <varlistentry><term>-version</term>
 71  <listitem><para>
 72  Displays the version of <application>lshw</application> and exits.
 73  </para></listitem></varlistentry>
 74  <varlistentry><term>-help</term>
 75  <listitem><para>
 76  Displays the available command line options and quits.
 77  </para></listitem></varlistentry>
 78  <varlistentry><term>-X</term>
 79  <listitem><para>
 80  Launch the X11 GUI (if available).
 81  </para></listitem></varlistentry>
 82  <varlistentry><term>-html</term>
 83  <listitem><para>
 84  Outputs the device tree as an HTML page.
 85  </para></listitem></varlistentry>
 86  <varlistentry><term>-xml</term>
 87  <listitem><para>
 88  Outputs the device tree as an XML tree.
 89  </para></listitem></varlistentry>
 90  <varlistentry><term>-json</term>
 91  <listitem><para>
 92  Outputs the device tree as a JSON object (JavaScript Object Notation).
 93  </para></listitem></varlistentry>
 94  <varlistentry><term>-short</term>
 95  <listitem><para>
 96  Outputs the device tree showing hardware paths, very much like the output of <productname>HP-UX</productname>'s <command>ioscan</command>.
 97  </para></listitem></varlistentry>
 98  <varlistentry><term>-businfo</term>
 99  <listitem><para>
100  Outputs the device list showing bus information, detailing <productname>SCSI</productname>, <productname>USB</productname>, <productname>IDE</productname> and <productname>PCI</productname> addresses.
101  </para></listitem></varlistentry>
102  <varlistentry><term>-dump <replaceable class="parameter">filename</replaceable></term>
103  <listitem><para>
104  Display output and dump collected information into a file (SQLite database).
105  </para></listitem></varlistentry>
106  <varlistentry><term>-class <replaceable class="parameter">class</replaceable></term>
107  <listitem><para>
108  Only show the given class of hardware. <replaceable class="parameter">class</replaceable> can be found using <command>lshw -short</command> or <command>lshw -businfo</command>.
109  </para></listitem></varlistentry>
110  <varlistentry><term>-C <replaceable class="parameter">class</replaceable></term>
111  <listitem><para>
112  Alias for <command>-class</command> <replaceable class="parameter">class</replaceable>.
113  </para></listitem></varlistentry>
114  <varlistentry><term>-enable <replaceable class="parameter">test</replaceable></term><term>-disable <replaceable class="parameter">test</replaceable></term>
115  <listitem><para>
116  Enables or disables a test. <replaceable class="parameter">test</replaceable> can be <command>dmi</command> (for <productname>DMI</productname>/<productname>SMBIOS</productname> extensions), <command>device-tree</command> (for <productname>OpenFirmware</productname> device tree), <command>spd</command> (for memory <productname>Serial Presence Detect</productname>), <command>memory</command> (for memory-size guessing heuristics), <command>cpuinfo</command> (for kernel-reported CPU detection), <command>cpuid</command> (for CPU detection), <command>pci</command> (for <productname>PCI</productname>/<productname>AGP access</productname>), <command>isapnp</command> (for <productname>ISA PnP</productname> extensions), <command>pcmcia</command> (for <productname>PCMCIA</productname>/<productname>PCCARD</productname>), <command>ide</command> (for <productname>IDE</productname>/<productname>ATAPI</productname>), <command>usb</command> (for <productname>USB</productname> devices),<command>scsi</command> (for <productname>SCSI</productname>) or <command>network</command> (for network interfaces detection).
117  </para></listitem></varlistentry>
118  <varlistentry><term>-quiet</term>
119  <listitem><para>
120  Don't display status.
121  </para></listitem></varlistentry>
122  <varlistentry><term>-sanitize</term>
123  <listitem><para>
124  Remove potentially sensitive information from output (IP addresses, serial numbers, etc.).
125  </para></listitem></varlistentry>
126  <varlistentry><term>-numeric</term>
127  <listitem><para>
128  Also display numeric IDs (for PCI and USB devices).
129  </para></listitem></varlistentry>
130  <varlistentry><term>-notime</term>
131  <listitem><para>
132  Exclude volatile attributes (timestamps) from output.
133  </para></listitem></varlistentry>
134  </variablelist>
135  </para>
136  
137  </refsect1>
138  
139  <refsect1><title>BUGS</title>
140  <para>
141  <application>lshw</application> currently does not detect 
142  <hardware>Firewire</hardware>(<hardware>IEEE1394</hardware>) devices.
143  </para>
144  
145  <para>
146  Not all architectures supported by GNU/Linux are fully supported (e.g.
147  <hardware>CPU</hardware> detection).
148  </para>
149  
150  <para>
151  "Virtual" <hardware>SCSI</hardware> interfaces used for <hardware>SCSI</hardware> emulation over <hardware>IDE</hardware> are not reported correctly yet.
152  </para>
153  
154  </refsect1>
155  
156  <refsect1><title>NOTES</title>
157  <para>
158  <application>lshw</application> must be run as super user or it will only report
159  partial information.
160  </para>
161  
162  </refsect1>
163  
164  <refsect1><title>FILES</title>
165  <para>
166  <variablelist>
167  
168  <varlistentry><term>/usr/local/share/pci.ids</term>
169  <term>/usr/share/pci.ids</term>
170  <term>/etc/pci.ids</term>
171  <term>/usr/share/hwdata/pci.ids</term>
172  <listitem><para>
173  A list of all known PCI ID's (vendors,  devices, classes and subclasses).
174  If compiled with zlib support, lshw will look for <filename>pci.ids.gz</filename> first, then for <filename>pci.ids</filename>.
175  </para></listitem></varlistentry>
176  
177  <varlistentry><term>/proc/bus/pci/*</term>
178  <listitem><para>
179  Used to access the configuration of installed PCI buses and devices.
180  </para></listitem></varlistentry>
181  
182  <varlistentry><term>/proc/ide/*</term>
183  <listitem><para>
184  Used to access the configuration of installed IDE buses and devices.
185  </para></listitem></varlistentry>
186  
187  <varlistentry><term>/proc/scsi/*, /dev/sg*</term>
188  <listitem><para>
189  Used to access the configuration of installed SCSI devices.
190  </para></listitem></varlistentry>
191  
192  <varlistentry><term>/dev/cpu/*/cpuid</term>
193  <listitem><para>
194  Used on x86 platforms to access CPU-specific configuration.
195  </para></listitem></varlistentry>
196  
197  <varlistentry><term>/proc/device-tree/*</term>
198  <listitem><para>
199  Used on PowerPC platforms to access OpenFirmware configuration.
200  </para></listitem></varlistentry>
201  
202  <varlistentry><term>/proc/bus/usb/*</term>
203  <listitem><para>
204  Used to access the configuration of installed USB buses and devices.
205  </para></listitem></varlistentry>
206  
207  <varlistentry><term>/sys/*</term>
208  <listitem><para>
209  Used on 2.6 kernels to access hardware/driver configuration information.
210  </para></listitem>
211  </varlistentry>
212  
213  </variablelist>
214  </para>
215  </refsect1>
216  
217  <refsect1><title>EXAMPLES</title>
218  <para>
219  <variablelist>
220  <varlistentry>
221  <term><command>lshw -short</command></term>
222  <listitem><para>
223  Lists hardware in a compact format.
224  </para></listitem>
225  </varlistentry>
226  
227  <varlistentry>
228  <term><command>lshw -class disk -class storage</command></term>
229  <listitem><para>
230  Lists all disks and storage controllers in the system.
231  </para></listitem>
232  </varlistentry>
233  
234  <varlistentry>
235  <term><command>lshw -html -class network</command></term>
236  <listitem><para>
237  Lists all network interfaces in HTML.
238  </para></listitem>
239  </varlistentry>
240  
241  <varlistentry>
242  <term><command>lshw -disable dmi</command></term>
243  <listitem><para>
244  Don't use DMI to detect hardware.
245  </para></listitem>
246  </varlistentry>
247  
248  </variablelist>
249  </para>
250  </refsect1>
251  
252  <refsect1><title>SEE ALSO</title>
253  <para><filename>/proc/*</filename>, <application>linuxinfo</application>(1), <application>lspci</application>(8), <application>lsusb</application>(8)
254  </para>
255  </refsect1>
256  
257  <refsect1><title>COPYING</title>
258  <para>
259  <application>lshw</application> is distributed under the GNU GENERAL PUBLIC LICENSE (GPL) version 2.
260  </para>
261  </refsect1>
262  
263  <refsect1><title>AUTHOR</title>
264  <para>
265  <application>lshw</application> is maintained by Lyonel Vincent
266  <email>lyonel@ezix.org</email>.
267  </para>
268  </refsect1>
269  
270  <refsect1><title>OTHER INFO</title>
271  <para>
272  The webpage for <application>lshw</application> is at 
273  <ulink url="http://lshw.ezix.org/"></ulink></para>
274  </refsect1>
275  
276  </refentry>
277