【微知】服务器如何获取服务器的SN序列号信息?(dmidecode -t 1)
文章目录
- 背景
- 命令
- dmidecode -t的数字代表的字段
背景
各种场景都需要获取服务器的SN(Serial Number),比如问题定位,文件命名,该部分信息在dmi中是标准信息,不同服务器,不同os都能用相同方式获取SN信息。本文记录快速获取SN的方式。
在“dmidecode”中,DMI是“Desktop Management Interface”的缩写,即桌面管理接口。
DMI是一种基于SMBIOS(System Management BIOS)的标准,它提供了一种在计算机系统中访问和管理硬件信息的方法。通过DMI,系统管理员和用户可以获取有关计算机硬件组件的详细信息,如处理器、内存、硬盘、主板、显卡等的规格、型号、序列号等。dmidecode工具就是利用DMI标准来获取并解码这些信息,以人类可读的格式呈现给用户,方便用户了解计算机硬件的配置情况。
命令
dmidecode -t 1或者:
dmidecode -t system
实操:
dmidecode -t的数字代表的字段
0 bios
1 system
DMI TYPESThe SMBIOS specification defines the following DMI types:Type Information────────────────────────────────────────────0 BIOS1 System2 Baseboard3 Chassis4 Processor5 Memory Controller6 Memory Module7 Cache8 Port Connector9 System Slots10 On Board Devices11 OEM Strings12 System Configuration Options13 BIOS Language14 Group Associations15 System Event Log16 Physical Memory Array17 Memory Device18 32-bit Memory Error19 Memory Array Mapped Address20 Memory Device Mapped Address21 Built-in Pointing Device22 Portable Battery23 System Reset24 Hardware Security25 System Power Controls26 Voltage Probe27 Cooling Device23 System Reset24 Hardware Security25 System Power Controls26 Voltage Probe27 Cooling Device28 Temperature Probe29 Electrical Current Probe30 Out-of-band Remote Access31 Boot Integrity Services32 System Boot33 64-bit Memory Error34 Management Device35 Management Device Component36 Management Device Threshold Data37 Memory Channel38 IPMI Device39 Power Supply40 Additional Information41 Onboard Devices Extended Information42 Management Controller Host Interface