ubuntu - 设备常见指令

查看主板支持多少个内存插槽(Memory Slots)

1. 查看所有内存设备(插槽)信息
复制代码
sudo dmidecode -t memory

lichang@ubuntu:~$ sudo dmidecode -t memory
[sudo] password for lichang: 
# dmidecode 3.2
Getting SMBIOS data from sysfs.
SMBIOS 3.6.0 present.
# SMBIOS implementations newer than version 3.2.0 are not
# fully supported by this version of dmidecode.

Handle 0x003A, DMI type 16, 23 bytes
Physical Memory Array
	Location: System Board Or Motherboard
	Use: System Memory
	Error Correction Type: None
	Maximum Capacity: 128 GB
	Error Information Handle: Not Provided
	Number Of Devices: 4

Handle 0x003B, DMI type 17, 92 bytes
Memory Device
	Array Handle: 0x003A
	Error Information Handle: Not Provided
	Total Width: Unknown
	Data Width: Unknown
	Size: No Module Installed
	Form Factor: Unknown
	Set: None
	Locator: Controller0-DIMMA1
	Bank Locator: BANK 0
	Type: Unknown
	Type Detail: None
	Speed: Unknown
	Manufacturer: Not Specified
	Serial Number: Not Specified
	Asset Tag: Not Specified
	Part Number: Not Specified
	Rank: Unknown
	Configured Memory Speed: Unknown
	Minimum Voltage: Unknown
	Maximum Voltage: Unknown
	Configured Voltage: Unknown
	Memory Technology: <OUT OF SPEC>
	Memory Operating Mode Capability: None
	Firmware Version: Not Specified
	Module Manufacturer ID: Unknown
	Module Product ID: Unknown
	Memory Subsystem Controller Manufacturer ID: Unknown
	Memory Subsystem Controller Product ID: Unknown
	Non-Volatile Size: None
	Volatile Size: None
	Cache Size: None
	Logical Size: None

Handle 0x003C, DMI type 17, 92 bytes
Memory Device
	Array Handle: 0x003A
	Error Information Handle: Not Provided
	Total Width: 64 bits
	Data Width: 64 bits
	Size: 16384 MB
	Form Factor: DIMM
	Set: None
	Locator: Controller0-DIMMA2
	Bank Locator: BANK 0
	Type: DDR4
	Type Detail: Synchronous
	Speed: 3600 MT/s
	Manufacturer: 0x0B92
	Serial Number: 12121239
	Asset Tag: 9876543210
	Part Number:                     
	Rank: 2
	Configured Memory Speed: 3600 MT/s
	Minimum Voltage: 1.2 V
	Maximum Voltage: 1.2 V
	Configured Voltage: 1.2 V
	Memory Technology: DRAM
	Memory Operating Mode Capability: Volatile memory
	Firmware Version: Not Specified
	Module Manufacturer ID: Bank 12, Hex 0x92
	Module Product ID: Unknown
	Memory Subsystem Controller Manufacturer ID: Unknown
	Memory Subsystem Controller Product ID: Unknown
	Non-Volatile Size: None
	Volatile Size: 16 GB
	Cache Size: None
	Logical Size: None

Handle 0x003D, DMI type 17, 92 bytes
Memory Device
	Array Handle: 0x003A
	Error Information Handle: Not Provided
	Total Width: Unknown
	Data Width: Unknown
	Size: No Module Installed
	Form Factor: Unknown
	Set: None
	Locator: Controller1-DIMMB1
	Bank Locator: BANK 0
	Type: Unknown
	Type Detail: None
	Speed: Unknown
	Manufacturer: Not Specified
	Serial Number: Not Specified
	Asset Tag: Not Specified
	Part Number: Not Specified
	Rank: Unknown
	Configured Memory Speed: Unknown
	Minimum Voltage: Unknown
	Maximum Voltage: Unknown
	Configured Voltage: Unknown
	Memory Technology: <OUT OF SPEC>
	Memory Operating Mode Capability: Volatile memory
	Firmware Version: Not Specified
	Module Manufacturer ID: Unknown
	Module Product ID: Unknown
	Memory Subsystem Controller Manufacturer ID: Unknown
	Memory Subsystem Controller Product ID: Unknown
	Non-Volatile Size: None
	Volatile Size: None
	Cache Size: None
	Logical Size: None

Handle 0x003E, DMI type 17, 92 bytes
Memory Device
	Array Handle: 0x003A
	Error Information Handle: Not Provided
	Total Width: 64 bits
	Data Width: 64 bits
	Size: 16384 MB
	Form Factor: DIMM
	Set: None
	Locator: Controller1-DIMMB2
	Bank Locator: BANK 0
	Type: DDR4
	Type Detail: Synchronous
	Speed: 3600 MT/s
	Manufacturer: 0x0B92
	Serial Number: 12121237
	Asset Tag: 9876543210
	Part Number:                     
	Rank: 2
	Configured Memory Speed: 3600 MT/s
	Minimum Voltage: 1.2 V
	Maximum Voltage: 1.2 V
	Configured Voltage: 1.2 V
	Memory Technology: DRAM
	Memory Operating Mode Capability: Volatile memory
	Firmware Version: Not Specified
	Module Manufacturer ID: Bank 12, Hex 0x92
	Module Product ID: Unknown
	Memory Subsystem Controller Manufacturer ID: Unknown
	Memory Subsystem Controller Product ID: Unknown
	Non-Volatile Size: None
	Volatile Size: 16 GB
	Cache Size: None
	Logical Size: None
2. 仅查看插槽数量和每个插槽的容量
复制代码
sudo dmidecode -t memory | grep -A5 "Memory Device$" | grep -E "Size|Locator"

lichang@ubuntu:~$ sudo dmidecode -t memory | grep -A5 "Memory Device$" | grep -E "Size|Locator"
	Size: No Module Installed
	Size: 16384 MB
	Size: No Module Installed
	Size: 16384 MB
相关推荐
开开心心就好15 小时前
发票合并打印工具,多页布局设置实时预览
linux·运维·服务器·windows·pdf·harmonyos·1024程序员节
无证驾驶梁嗖嗖16 小时前
用Plex打造随身私人影院告别影音杂乱,必须加上cpolar突破地域限制!
ubuntu
css趣多多16 小时前
add组件增删改的表单处理
java·服务器·前端
予枫的编程笔记16 小时前
【Linux进阶篇】从基础到实战:grep高亮、sed流编辑、awk分析,全场景覆盖
linux·sed·grep·awk·shell编程·文本处理三剑客·管道命令
Sheep Shaun16 小时前
揭开Linux的隐藏约定:你的第一个文件描述符为什么是3?
linux·服务器·ubuntu·文件系统·缓冲区
Tfly__16 小时前
在PX4 gazebo仿真中加入Mid360(最新)
linux·人工智能·自动驾驶·ros·无人机·px4·mid360
野犬寒鸦16 小时前
从零起步学习并发编程 || 第七章:ThreadLocal深层解析及常见问题解决方案
java·服务器·开发语言·jvm·后端·学习
陈桴浮海16 小时前
【Linux&Ansible】学习笔记合集二
linux·学习·ansible
生活很暖很治愈16 小时前
Linux——环境变量PATH
linux·ubuntu
?re?ta?rd?ed?16 小时前
linux中的调度策略
linux·运维·服务器