| 
  • If you are citizen of an European Union member nation, you may not use this service unless you are at least 16 years old.

  • You already know Dokkio is an AI-powered assistant to organize & manage your digital files & messages. Very soon, Dokkio will support Outlook as well as One Drive. Check it out today!

View
 

Find Hardware Specs (Details) on your Computer

Page history last edited by Paul G. Taylor 14 years ago

Following this blog : --

 

Find Hardware Specs (Details) on your Computer

 

I have run the following : --

 

[This is my production machine ]

 

paul@paul-ArtistX07:~$ sudo lshw -xml > lshw-2010-04-14.xml    [This format needs an accompanying style sheet, apparently] 

 

paul@paul-ArtistX07:~$ sudo lshw -html > lshw-2010-04-14.html  [This format will display in your browser] 

 

paul@paul-ArtistX07:~sudo lshw -html   | gzip lshw-2010-04-14.html   [As a compressed file  lshw-2010-04-14.html.gz - unzip with 'gunzip  lshw-2010-04-14.html.gz']

 

paul@paul-ArtistX07:~$ sudo lshw -short  >  lshw-short-2010-04-14.txt   [As a compressed file lshw-short-2010-04-14.txt.gz   - unzip with 'gunzip lshw-short-2010-04-14.txt.gz']

 

the resultant files are attached here. Click on the links above to display.

 

For comparison, here are the details of these files : --

 

paul@paul-ArtistX07:~$ ls -l lshw*
-rw-r--r-- 1 paul paul 83886 2010-04-14 16:22 lshw-2010-04-14.html
-rw-r--r-- 1 paul paul  6090 2010-04-14 16:02 lshw-2010-04-14.html.gz
 [that's 7.25 % of the raw html file size!]
-rw-r--r-- 1 paul paul 49153 2010-04-14 15:59 lshw-2010-04-14.xml
-rw-r--r-- 1 paul paul  1076 2010-04-14 16:37 lshw-short-2010-04-14.txt.gz
paul@paul-ArtistX07:~$

 

Of course you can also get this sort of information by running an application such as 'hardinfo', but it is kind of interesting to get it from the command line so easily.

 

Note also these options, etc, from the help file included in 'lshw'

 

paul@paul-ArtistX07:~$ sudo lshw -h
Hardware Lister (lshw) - B.02.13
usage: lshw [-format] [-options ...]
       lshw -version

        -version        print program version (B.02.13)

format can be
        -html           output hardware tree as HTML
        -xml            output hardware tree as XML
        -short          output hardware paths
        -businfo        output bus information

options can be
        -class CLASS    only show a certain class of hardware
        -C CLASS        same as '-class CLASS'
        -c CLASS        same as '-class CLASS'
        -disable TEST   disable a test (like pci, isapnp, cpuid, etc. )
        -enable TEST    enable a test (like pci, isapnp, cpuid, etc. )
        -quiet          don't display status
        -sanitize       sanitize output (remove sensitive information like serial numbers, etc.)
        -numeric        output numeric IDs (for PCI, USB, etc.)
 
[Information for my test-bed machine ]

paul@paul-testbed:~$ sudo lshw -html > lshw-tb-2010-04-14.html
paul@paul-testbed:~ gzip lshw-tb-2010-04-14.html  lshw-tb-2010-04-14.html.gz   

paul@paul-testbed:~ sudo lshw -short >  lshw-tb-short-2010-04-14.txt
paul@paul-testbed:~ gzip lshw-tb-short-2010-04-14.txt 
lshw-tb-short-2010-04-14.txt.gz 

Comments (0)

You don't have permission to comment on this page.