当前位置:首页 > linux > 正文

linux查看所有硬件配置命令

  • linux
  • 2024-04-30 14:16:15
  • 643

1. lshw
lshw 命令用于列出系统中所有硬件设备的信息,包括:
CPU
内存
磁盘
网络设备
USB 设备
语法:
lshw
示例输出:
-core
description: Core Complex
product: Core Complex
vendor: Intel Corporation
physical id: 0
bus info: cpu@0
version: 007
width: 64 bits
clock: 1200.08MHz
capabilities: fpu fpu_exception wp vme de pse tsc msr pae mce cx8 apic mtrr pge mca cmov pat pse36 clflush mmx fxsr sse sse2 ss ht tm pbe syscall nx pdpe1gb rdtscp lm constant_tsc arch_perfmon pebs bts rep_good nopl xtopology nonstop_tsc aperfmperf pni dtes64 monitor ds_cpl vmx est tm2 ssse3 sdbg fma cx16 xtpr pdcm pcid sse4_1 sse4_2 x2apic movbe popcnt tsc_deadline_timer aes xsave avx f16c rdrand lahf_lm abm 3dnowpre fetch cpuid pku ospke vaes rdseed clzero xsaves avx2 smep bmi1 avx512f avx512dq rdtscp_4k fpu64 xsaveopt xsavec xgetbv1 xsaves_extended arat nibp sysretar
configuration: cores=2 enabled=1
-cpu
description: CPU
product: Intel(R) Core(TM) i7-8550U CPU @ 1.80GHz
vendor: Intel Corporation
physical id: 1
bus info: cpu@0
version: 007
serial: To Be Filled By O.E.M.
slot: CPU1
size: 128KiB
capacity: 128KiB
width: 64 bits
clock: 1200.08MHz
capabilities: x86-64 fpu fpu_exception wp vme de pse tsc msr pae mce cx8 apic mtrr pge mca cmov pat pse36 clflush mmx fxsr sse sse2 ss ht tm pbe syscall nx pdpe1gb rdtscp lm constant_tsc arch_perfmon pebs bts rep_good nopl xtopology nonstop_tsc aperfmperf pni dtes64 monitor ds_cpl vmx est tm2 ssse3 sdbg fma cx16 xtpr pdcm pcid sse4_1 sse4_2 x2apic movbe popcnt tsc_deadline_timer aes xsave avx f16c rdrand lahf_lm abm 3dnowpre fetch cpuid pku ospke vaes rdseed clzero xsaves avx2 smep bmi1 avx512f avx512dq rdtscp_4k fpu64 xsaveopt xsavec xgetbv1 xsaves_extended arat nibp sysretar
configuration: cores=2 enabled=1
topology: core id=0
2. dmidecode
dmidecode 命令用于解码 DMI (桌面管理界面) 表,其中包含有关系统硬件和 BIOS 设置的信息。
语法:
dmidecode
示例输出:
# dmidecode 2.12
Getting SMBIOS data from sysfs.
SMBIOS 3.0 pre sent.
Handle 0x0000, DMI type 0, 27 bytes
BIOS Information
Vendor: American Megatrends Inc.
Version: P1.10A
Release Date: 08/21/2018
Address: 0xF0000
Runtime Size: 64 kB
ROM Size: 512 kB
Features: PCI is supported, AGP is not supported
Characteristics:
ISA is supported
PCI slots are supported
PC Card (PCMCIA) is supported
BIOS is upgradeable
BIOS shadowing is allowed
Boot from CD is supported
Selectable boot is supported
EDD is supported
Print screen key is supported
8042 keyboard services are supported
Serial/PS2 mouse is supported
ACPI is supported
USB legacy is supported
Boot from USB is supported
BIOS Boot Specification is supported
Handle 0x0001, DMI type 1, 24 bytes
System Information
Manufacturer: Lenovo
Product Name: IdeaPad 5-14ARE05
Version: NB51A27
Serial Number: MP21J085
UUID: 7e754a8a-0c59-11eb-9ca4-080027557e29
SKU Number: 82C70029US
Family: IdeaPad 5
Handle 0x0002, DMI type 4, 23 bytes
Processor Information
Socket Designation: FCBGA1440
Type: Central Processor
Family: Core i7
Manufacturer: Intel
ID: 97 06 04 05 78 06 13 00 F1 08 11 81 05 D0 38 00
Version: Intel(R) Core(TM) i7-10710U CPU @ 1.10GHz
Voltage: 1.2 V
External Clock: 100 MHz
Maximum Speed: 4.7 GHz
Current Speed: 1.1 GHz
Status: Populated, Enabled
Upgrade: On-line spare
3. lspci
lspci 命令用于列出系统中的 PCI 设备信息,包括:
设备类型
厂商
设备 ID
语法:
lspci
示例输出:
00:00.0 Host bridge: Intel Corporation 8th Gen Core Processor Host Bridge/DRAM Registers (rev 06)
00:01.0 PCI bridge: Intel Corporation Xeon E3-1200 v6/7th Gen Core Processor PCI Expre ss Root Port (rev 06)
00:02.0 VGA compatible controller: Intel Corporation UHD Graphics 620 (rev 07)
00:14.0 USB controller: Intel Corporation Sunrise Point-LP USB 3.0 xHCI Controller (rev 21)
00:14.2 Signal processing controller: Intel Corporation Sunrise Point-LP Thermal Subsystem (rev 21)
00:16.0 Communication controller: Intel Corporation Cannon Lake PCH Serial IO I2C Controller #0 (rev 21)
00:17.0 SATA controller: Intel Corporation Cannon Lake PCH SATA Controller (rev 21)
00:1f.0 ISA bridge: Intel Corporation Sunrise Point-LP LPC Controller (rev 21)
00:1f.2 Memory controller: Intel Corporation Sunrise Point-LP PMC (rev 21)
01:00.0 Network controller: Realtek Semiconductor Co., Ltd. RTL8111/8168/8411 PCI Expre ss Gigabit Ethernet Controller (rev 15)
03:00.0 Ethernet controller: Realtek Semiconductor Co., Ltd. RTL8111/8168/8411 PCI Expre ss Gigabit Ethernet Controller (rev 15)
4. lsusb
lsusb 命令用于列出系统中的 USB 设备信息,包括:
设备类型
厂商
产品 ID
语法:
lsusb
示例输出:
Bus 001 Device 001: ID 1d6b:0003 Linux Foundation 3.0 root hub
Bus 002 Device 002: ID 04f2:b37f Chicony Electronics Co., Ltd Biometric Fingerprint Reader
Bus 002 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
5. lsscsi
lsscsi 命令用于列出系统中的 SCSI 设备信息,包括:
设备类型
厂商
型号
语法:
lsscsi
示例输出:
[0:0:0:0] disk ATA ST2000LM003-HN-W10102 ATA3.00
[1:0:0:0] disk ATA ST500LM022 HN-M1