命令 |
用途 |
输出示例 |
lshw |
列出所有硬件设备及其详细信息 |
- Processor: Intel(R) Core(TM) i7-6700K CPU @ 4.00GHz
- Memory: 16GB DDR4 SDRAM
- Graphics: NVIDIA GeForce GTX 1080
|
lspci |
列出所有 PCI 设备及其详细信息 |
- 00:00.0 Host bridge: Intel Corporation Xeon E3-1200 v6/7th Gen Core Processor Host Bridge/DRAM Registers
- 00:02.0 VGA compatible controller: Intel Corporation HD Graphics 630
- 00:14.0 USB controller: Intel Corporation Sunrise Point-LP USB 3.0 xHCI Controller
|
dmidecode |
显示 DMI (Desktop Management Interface) 信息 |
- System Information
- Manufacturer: Dell Inc.
- Product Name: OptiPlex 7050
- Serial Number: 1234567890
- Processor Information
- Vendor: Intel Corporation
- Name: Intel(R) Core(TM) i7-6700K CPU @ 4.00GHz
- Speed: 4000 MHz
|
hardinfo |
提供详细的硬件信息 |
- System
- Manufacturer: Dell Inc.
- Model: OptiPlex 7050
- SerialNumber: 1234567890
- Processor
- Vendor: Intel Corporation
- Name: Intel(R) Core(TM) i7-6700K CPU @ 4.00GHz
- Cores: 4
- Memory
- Size: 16GB
- Type: DDR4 SDRAM
- Speed: 2133 MHz
|
在 Linux 系统中,可以通过多种命令行工具来查看设备型号和其他硬件信息。
以下是一些常用命令及其用途:
lshw:枚举所有已安装的硬件设备及其详细信息,包括型号、制造商和属性。
lspci:列出所有 PCI 设备及其详细信息,包括型号、供应商和总线信息。
dmidecode:解析来自 DMI (Desktop Management Interface) 的信息,该信息包含有关系统、处理器、内存和其他组件的详细信息。
hardinfo:提供广泛的硬件信息,包括系统、处理器、内存、显卡、存储和网络设备的详细信息。
![](https://img0.baidu.com/it/u=2133059912,660323508&fm=253.jpg)