查看硬件資訊( lspci & lshw & lsdev & lshal )

最後更新: 2015-05-19

 

目錄

  • lspci
  • lshw
  • lshal

lspci

lspci -v

lspci -t

 


lshw

 

Install

yum install lshw

apt-get install lshw

i.e.

# Lists all disks and storage controllers in the system.

# lshw -c storage

lshw -class disk -class storage

  *-cdrom
       description: DVD-RAM writer
       product: DVD+-RW ????
       vendor: HL-DT-ST
       physical id: 0.0.0
       bus info: scsi@13:0.0.0
       logical name: /dev/cdrom
       logical name: /dev/cdrw
       logical name: /dev/dvd
       logical name: /dev/dvdrw
       logical name: /dev/scd0
       logical name: /dev/sr0
       version: A3C1
       capabilities: removable audio cd-r cd-rw dvd dvd-r dvd-ram
       configuration: ansiversion=5 status=nodisc
  *-disk:0
       description: ATA Disk
       product: TOSHIBA ????
       vendor: Toshiba
       physical id: 0.5.0
       bus info: scsi@14:0.5.0
       logical name: /dev/sda
       version: FK5D
       serial: 69EAK91QF7DE
       size: 3726GiB (4TB)
       capacity: 3726GiB (4TB)
       capabilities: 7200rpm gpt-1.00 partitioned partitioned:gpt
       configuration: ansiversion=6 guid=... logicalsectorsize=512 sectorsize=512

Other class

  • network
  • memory

 


lsdev

 

Displays data about all devices of which the system is aware.

apt-get install procinfo

Device            DMA   IRQ  I/O Ports
------------------------------------------------
......
ehci_hcd:usb2            17
ohci_hcd:usb5            18
eth0                     55
radeon                   56
rtc0                      8    0070-0071
serial                    4    03f8-03ff
vesafb                         03c0-03df

 


lshal

............
udi = '/org/freedesktop/Hal/devices/storage_model_LD_0_RAID5_1430G'
  block.storage_device = '/org/freedesktop/Hal/devices/storage_model_LD_0_RAID5_1430G'  (string)
  info.udi = '/org/freedesktop/Hal/devices/storage_model_LD_0_RAID5_1430G'  (string)
  storage.requires_eject = false  (bool)
  storage.hotpluggable = false  (bool)
  info.capabilities = {'storage', 'block'} (string list)
  info.category = 'storage'  (string)
  info.product = 'LD 0 RAID5 1430G'  (string)
  info.vendor = 'MegaRAID'  (string)
  storage.removable = false  (bool)
  storage.physical_device = '/org/freedesktop/Hal/devices/pci_1028_13_scsi_host_scsi_device_lun0'  (string)
  storage.lun = 0  (0x0)  (int)
  storage.firmware_version = '521S'  (string)
  storage.vendor = 'MegaRAID'  (string)
  storage.model = 'LD 0 RAID5 1430G'  (string)
  storage.drive_type = 'disk'  (string)
  storage.automount_enabled_hint = true  (bool)
  storage.media_check_enabled = false  (bool)
  storage.no_partitions_hint = false  (bool)
  storage.bus = 'scsi'  (string)
  block.is_volume = false  (bool)
  block.minor = 0  (0x0)  (int)
  block.major = 8  (0x8)  (int)
  block.device = '/dev/sda'  (string)
  linux.hotplug_type = 3  (0x3)  (int)
  info.parent = '/org/freedesktop/Hal/devices/pci_1028_13_scsi_host_scsi_device_lun0'  (string)
  linux.sysfs_path_device = '/sys/block/sda'  (string)
  linux.sysfs_path = '/sys/block/sda'  (string)