6splus,Linux怎样检查硬件信息之lshw指令,李可

admin 2019-04-19 阅读:309


lshw东西简介

本文首要介绍lshw指令,该指令是Linux系统管理中较为常用的一个指令行东西,用于检查硬件信息。大都Linux发行版默许情况下并没有集成该东西,本文将会解说怎么运用lshw指令检查服务器硬件信息。

装置东西:
CentOS7.6为例:

[root@zcwyou ~]# yum -y install lshw

1. 检查网卡信息

指令:

[root@zcwyou ~]# lshw  -C ne6splus,Linux怎样检查硬件信息之lshw指令,李可twork

输出信息:
*-network
description: Ethernet interface
product: RTL8101E/RTL8102E PCI Express Fast Ethernet controller
vendor: Realtek Semiconductor Co., Ltd.
physical id: 0
bus info: pci@0000:01:00.0
logical name: eth0
version: 05
serial: 00:e0:4c:36:01:8b
size: 100Mbit/s
c蚊仙缘apacity: 100Mbit/s
width: 64 bits
clock: 33MHz
capabilities: pm msi pciexpress msix vpd bus_master cap_list ethernet physical tp mii 10bt 10bt-fd 100bt 100bt-fd autonegotiation
configuration: autonegotiation=on broadcast=yes driver=r8169 driverversi潘湘湘on=2.3LK-NAPI duplex=full firmware=rtl_nic/rtl8105e-1.fw ip=59.37.83.138 latency=0 link=yes multicast=yes port=MII speed=100Mbit/s
resources: irq:26 ioport:e800(size=256) memory:fdfff000-fdffffff(prefetchable) memory:fdff8000-fdffbfff(prefetchable)

2. 检查内存信息

指令:

[root@zcwyou ~]# lshw -C memory

输出信息:
-firmware
description: BIOS
vendor: Dell Inc.
physical id: 0
version: 1.13.0
date: 03/02/2018
size: 64KiB
capacity: 4MiB
capabilities: isa pci pnp upgrade shadowing cdboot bootselect edd int13floppytoshiba int13floppy360 int13flop湖南城市学院才智学校py1200 int13floppy720 int9keyboard int14serial int10video acpi usb biosbootspecification netboot
-cache:0
description: L1 cache
physical id: 700
size: 128KiB
capacity: 128KiB
capabilities: internal writjperoticae-back d尘欲香夜缠双ata
configuration: level=1
-cache:1
description: L2 cache
physical id: 701
size: 1M6splus,Linux怎样检查硬件信息之lshw指令,李可iB
cap女性的性acity: 2MiB
capabilities: internal write-back unified
configuration: 蔡日新level=2
-cache:2
description: L3 cache
physical id: 702
size: 12MiB
capacity: 12MiB
ca调教师pabilities: internal write-back unified
configuration: level=3
-memory
description: System Memory
physical id: 1000
slot: System board or motherboard
size: 32GiB
capabilities: ecc
configuration: errordetection=multi-bit-ecc
-bank:0
description: DIMM DDR3 Synchronous Registered (Bu6splus,Linux怎样检查硬件信息之lshw指令,李可ffered) 1爱丽丝伊菲迪亚公主333 MHz (0.8 ns)
product: M393B1K70DH0-YH9
vendor: 00CE00B380CE
physical id: 0
serial: 83BB0BB1
slot: DIMM仲景艾宝_A1
size: 8GiB
width: 64 bits
clock: 1333MHz (0.8ns)
-bank:1
description: DIMM DDR3 Synchronous Registered (Buffered) 1333 MHz (0.8 ns)
product: M393B1K70DH0-YH9
vendor: 00CE00B38狱乐营0CE
physical id: 1
serial: 83BB0BB0
slot: DIMM_A2
size: 8GiB
width: 64 bits
clock: 1333MHz (0.8ns)
-bank:2
description: DIMM DDR3 Synchron佳人乐聊6splus,Linux怎样检查硬件信息之lshw指令,李可ous Registered (Buffered) 1333 MHz (0.8 ns)
product: M393B1K70DH0-YH9
vendor: 00CE00B380CE
physical id: 2
serial: 83BB0BDD
slot: DIMM_A3
size: 8GiB
width: 64 bits
clock: 1333MHz (0.8ns)
-bank:3
descripti6splus,Linux怎样检查硬件信息之lshw指令,李可on: DIMM DDR3 Synchronous Registered (Buffered) 1333 MHz (0.8 ns)
product: M393B1K70DH0-YH9
vendor: 00CE00B380CE
physical id: 3
serial: 83BB0BAC
slot: DIMM_A4
size: 8GiB
width: 64 bits
clock: 1333MHz (0.8ns)
-bank:4
description: DIMM DDR3 Synchronous [empty]
physical id: 4
slot: DIMM_B1
wid6splus,Linux怎样检查硬件信息之lshw指令,李可th: 64 bits
-bank:5
description: DIMM DDR3 Synchronous [empty]
physical id: 5
slot: DIMM_B2
width: 64 bits
-bank:6
description: DIMM DDR3 Synchronous [empty]
physical id: 6
slot: DIMM_B3
width: 64 bits

*-bank:7
description: DIMM DDR3 Synchronous [empty]
physical id: 7
slot: DIMM_B4
width: 64 bits

3. 检查CPU信息

不需要运用lshw指令

[root@zcwyou ~]# cat /proc/cpuinfo |more

输出成果:

processor    : 0
vendor_id    : GenuineIntel
cpu family    : 6
model        : 45
model name    : Intel(R) Xeon(R) CPU E5-2630 0 @ 2.30GHz
stepping    : 7
microcode    : 0x710
cpu MHz        : 2294.471
cache size    : 1谌天舒5360 KB
physical id    : 0
siblings    : 2
core id        : 0
cpu cores    : 2
apicid        : 0
initial apicid    : 0
fpu        : yes
fpu_exception    : yes
cpuid level    : 13
wp        : yes
flags        : fpu vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca cmov pat pse36 clflush dts mmx fxsr sse sse2 ss ht syscall nx rdtscp lm constant_tsc arch_perfmon pebs bts nopl xt
opology tsc_reliable n巨阴族onstop_tsc cpuid 色漫aperfmperf pni pclmulqdq ssse3 cx16 pcid sse4_1 sse4_2 x2apic popcnt tsc_deadline_timer aes xsave avx hypervisor lahf_lm epb pti tsc_adjust dtherm ida
arat pln pts
bugs        : cpu_meltdown spectre_v1秦王太妃传 spectre_v2 spec_store_bypass l1tf
bog沈诺傅擎omips    : 4588.94
clflush size    : 64
cac闪字签he_alignment    : 64
address sizes6splus,Linux怎样检查硬件信息之lshw指令,李可    : 42 bits physical, 48 bits virtual
power management:

4. 总结

Lin寿司王子ux运用lshw检查各种硬件信息。

微信查找大众号“智传网优”或许长按以下二维码,然后挑选“辨认图中二维码”直接开端自助视频学习,欢迎留言或与咱们讲师直接交流。

Linux学习QQ群:557371664