lshw(Hardware Lister)是另外一个可以查看硬件信息的工具,不仅如此,它还可以用来做一些硬件的benchmark。

lshw is a small tool to extract detailed information on the hardware configuration of the machine. It can report exact memory configuration, firmware version, mainboard configuration, CPU version and speed, cache configuration, bus speed, etc. on DMI-capable x86 or IA-64 systems and on some PowerPC machines (PowerMac G4 is known to work).

这个工具其实就是用/proc里面读取一些文件来显示相关的信息,它用到了如下文件和目录(下的文件):
 /proc/cpuinfo  显示CPU信息
 /proc/bus/pci  显示pci信息
 /proc/scsi   显示scsi信息
 /proc/net/dev  显示网络设备信息
 /proc/kcore   从内存映像读取相关信息
 /proc/ide   显示IDE设备信息
 /proc/devices
 /proc/mounts
 /proc/fstab

下载和安装:
 -------------------------------------------------------------
 cd /tmp
 wget http://ezix.org/software/files/lshw-B.02.14.tar.gz

 tar lshw-B.02.14.tar.gz
 cd lshw-B.02.14
 make && make install
 -------------------------------------------------------------
 用法:
 1.最简单的用法:
 # lshw

 和dmidecode一样,输出一大堆的东西。
 
 2. 以html/xml格式输出
 # lshw -html >info.html

 # lshw -xml >info.xml

3. 显示设备列表,输出包括设备路径(path)、类别(class)以及简单描述
 # lshw -short

 
 4. 显示设备列表,输出包括总线信息、SCSI、USB、IDE、PCI地址等。
 # lshw -businfo

 
 5. 显示指定类别的设备
 # lshw -C class

 # lshw -class class

 这里的class可以通过lshw -short来查看。比如
 # lshw -C memory

然后我们看下help信息,这个比较简单,能看懂


user@h-desktop:~$ lshw -h
Hardware Lister (lshw) - B.02.16
usage: lshw [-format] [-options ...]
       lshw -version

-version        print program version (B.02.16)  // 查看版本

format can be  // 格式化后输出,如例子2
    -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  // 按类型输出,如network
    -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.)  

参考:

http://linux.die.net/man/1/lshw

http://www.sanotes.net/html/y2009/316.html

lshw查看系统硬件信息的更多相关文章

  1. 利用CMD查看系统硬件信息

    利用CMD查看系统硬件信息对于在windows下查看系统信息大家一定不陌生了,我现在说几个最常用的方法,对命令感兴趣的朋友看看,(给菜鸟看的,老手就不要笑话我了,大家都是从那个时候过来的,^_^).一 ...

  2. centos 7 查看系统/硬件信息及运维常用命令+联想Y430P无线网卡驱动安装

     centos 7 查看系统/硬件信息及运维常用命令 当前环境:联想Y430P  CentOS 7.3 [root@yan-001 ~] # uname -a # 查看内核/操作系统/CPU信息的Li ...

  3. Linux查看系统硬件信息命令

    Linux查看系统硬件信息命令 查看磁盘类型(是否SSD) cat /sys/block/sda/queue/rotational code:0 SSD盘 code:1 SATA盘 查看物理CPU个数 ...

  4. Ubuntu 14.10 下查看系统硬件信息(实例详解)

    linux查看系统的硬件信息,并不像windows那么直观,这里我罗列了查看系统信息的实用命令,并做了分类,实例解说. cpu lscpu命令,查看的是cpu的统计信息. blue@blue-pc:~ ...

  5. Linux 查看系统硬件信息(实例详解)

    原文链接:http://www.cnblogs.com/ggjucheng/archive/2013/01/14/2859613.html linux查看系统的硬件信息,并不像windows那么直观, ...

  6. Linux 查看系统硬件信息汇总 (部份实例详解Centoso为例)

    1.cpu #lscpu命令,查看的是cpu的统计信息.(部分旧版本不支持) Disk /dev/sda: bytes heads, sectors/track, cylinders Units = ...

  7. Linux 查看系统硬件信息[转]

    原文:http://www.cnblogs.com/ggjucheng/archive/2013/01/14/2859613.html linux查看系统的硬件信息,并不像windows那么直观,这里 ...

  8. Linux 查看系统硬件信息

    linux查看系统的硬件信息,并不像windows那么直观,这里我罗列了查看系统信息的实用命令,并做了分类,实例解说. cpu lscpu命令,查看的是cpu的统计信息. blue@blue-pc:~ ...

  9. Linux查看系统硬件信息命令汇总

    对工作中,经常用的查看系统硬件命令的一个简单总结 1.查看磁盘类型(是否SSD盘)cat /sys/block/sda/queue/rotational注意:命令中的sba是你的磁盘名称,可以通过df ...

随机推荐

  1. Windbg查看w3wp进程占用的内存及.NET内存泄露,死锁分析

    https://www.cnblogs.com/startpoint/p/4194052.html https://www.cnblogs.com/lyl6796910/p/7613664.html ...

  2. 100.64.0.0/10运营商级(Carrier-grade)NAT保留IP地址

    在一次跟踪路由的网络操作时发现自己路由器下一跳路由节点的IP地址比较奇怪,是100.64.0.1.好奇促使我查询了这个IP地址的归属,结果是保留地址,到这里觉得比较奇怪了,按照常理以IPv4为例保留的 ...

  3. pvalue for go kegg enrichment

      Simple, fast implementation of Fisher’s exact test. . For example, for the following table: o Havi ...

  4. win iso download

    http://rufus.akeo.ie/ window iso download http://win.86tyu.cn/ylmf32win7.html

  5. 温故而知新-WebSocket 教程

    一.为什么需要 WebSocket? 初次接触 WebSocket 的人,都会问同样的问题:我们已经有了 HTTP 协议,为什么还需要另一个协议?它能带来什么好处? 答案很简单,因为 HTTP 协议有 ...

  6. optparse模块

    optparse模块主要是用来对参数的记录,相对来说比较灵活, 例子代码如下: #!/usr/bin/env python from optparse import OptionParser usag ...

  7. vue设置title和ioc图标

    vue设置ioc图标和title 1.ioc图标设置 在根目录中的index.html中引入代码: <link rel="shortcut icon" type=" ...

  8. SpringData JPA示例

    SpringData JPA只是SpringData中的一个子模块 JPA是一套标准接口,而Hibernate是JPA的实现 SpringData JPA 底层默认实现是使用Hibernate 1.  ...

  9. Core1.1环境下,自己实现的一个简单的CRUD框架(反射实现)

    我实现了一个简单的EF框架,主要用于操纵数据库.实现了对数据库的基本操纵--CRUD 这是项目结构 这是一个 core 下的 DLL 写了一个数据库工厂,用于执行sql语句.调用sql语句工厂 写了一 ...

  10. 第2章地址Address(WCF全面解析3)

    WCF顾明思义,就是在Windows平台下解决通信(C,Communication)的基础框架(F,Foundation)问题. 终结点是WCF最为核心的对象,因为它承载了所有通信功能.服务通过相应的 ...