Dmidecode
一、Dmidecode简介
DMI (Desktop Management Interface, DMI)就是帮助收集电脑系统信息的管理系统,DMI信息的收集必须在严格遵照SMBIOS规范的前提下进行。 SMBIOS(System Management BIOS)是主板或系统制造者以标准格式显示产品管理信息所需遵循的统一规范。SMBIOS和DMI是由行业指导机构Desktop Management Task Force (DMTF)起草的开放性的技术标准,其中DMI设计适用于任何的平台和操作系统。
DMI充当了管理工具和系统层之间接口的角色。它建立了标准的可管理系统更加方便了电脑厂商和用户对系统的了解。DMI的主要组成部分是Management Information Format (MIF)数据库。这个数据库包括了所有有关电脑系统和配件的信息。通过DMI,用户可以获取序列号、电脑厂商、串口信息以及其它系统配件信息。
dmidecode的输出格式一般如下:
Handle × DMI type , bytes Base Board Information Manufacturer:Intel Product Name: C440GX+ Version: - Serial Number: INCY92700942
其中的前三行都称为记录头(recoce Header), 其中包括了:
- recode id(handle): DMI表中的记录标识符,这是唯一的,比如上例中的Handle 0×0002。
- dmi type id: 记录的类型,譬如说:BIOS,Memory,上例是type 2,即”Base Board Information”
- recode size: DMI表中对应记录的大小,上例为8 bytes.(不包括文本信息,所有实际输出的内容比这个size要更大。)记录头之后就是记录的值
- decoded values: 记录值可以是多行的,比如上例显示了主板的制造商(manufacturer)、model、version以及serial Number。
二、Dmidecode的作用
dmidecode的作用是将DMI数据库中的信息解码,以可读的文本方式显示。由于DMI信息可以人为修改,因此里面的信息不一定是系统准确的信息。
三、安装Dmidecode
Dmidecode 在主流的 Linux 发行版中都可以找到,只需通过所用发行版的包管理器安装即可,如:
apt-get install dmidecode
或者使用官方包安装:
Dmidecode源码包下载地址:http://download.savannah.GNU.org/releases/dmidecode/
Win版本下载地址:http://gnuwin32.sourceforge.net/packages/dmidecode.htm
四、dmidecode命令用法详解
不带选项执行 dmidecode 通常会输出所有的硬件信息。Dmidecode 有个很有用的选项 -t,可以按指定类型输出相关信息,假如要获得处理器方面的信息,则可以执行
dmidecode -t processor
输出:
# dmidecode 2.10 SMBIOS 2.6 present. Handle , bytes Processor Information Socket Designation: CPU Type: Central Processor Family: Xeon Manufacturer: Intel ID: A5 FF FB EB BF Signature: Type , Family , Model , Stepping Flags: FPU (Floating-point unit on-chip) VME (Virtual mode extension) DE (Debugging extension) ------ Usage: dmidecode [OPTIONS] Options are: -d, --dev-mem FILE Read memory from device FILE (default: /dev/mem) 从设备文件读信息,输出内容与不加参数标准输出相同 -h, --help Display this help text and exit 显示帮助信息 -q, --quiet Less verbose output 显示更少的简化信息 -s, --string KEYWORD Only display the value of the given DMI string 只显示指定DMI字符串的信息 -t, --type TYPE Only display the entries of given type 只显示指定条目的信息 -u, --dump Do not decode the entries 显示未解码的原始条目内容 --dump-bin FILE Dump the DMI data to a binary file --from-dump FILE Read the DMI data from a binary file -V, --version Display the version and exit 显示版本信息
五、dmidecode参数string及type列表
()Valid string keywords are: bios-vendor bios-versio bios-release-date system-manufacturer system-product-name system-version system-serial-number system-uuid baseboard-manufacturer baseboard-product-name baseboard-version baseboard-serial-number baseboard-asset-tag chassis-manufacturer chassis-type chassis-version chassis-serial-number chassis-asset-tag processor-family processor-manufacturer processor-version processor-frequency ()Valid type keywords are: bios system baseboard chassis processor memory Cache connector slot ()type全部编码列表 BIOS System Base Board Chassis Processor Memory Controller Memory Module Cache Port Connector System Slots On Board Devices OEM Strings System Configuration Options BIOS Language Group Associations System Event Log Physical Memory Array Memory Device -bit Memory Error Memory Array Mapped Address Memory Device Mapped Address Built-in Pointing Device Portable Battery System Reset Hardware Security System Power Controls Voltage Probe Cooling Device Temperature Probe Electrical Current Probe Out-of-band Remote Access Boot Integrity Services System Boot -bit Memory Error Management Device Management Device Component Management Device Threshold Data Memory Channel IPMI Device Power Supply Additional Information Onboard Device
六、命令用法示例
查看服务器型号:
dmidecode | grep 'Product Name'
查看主板的序列号:
dmidecode |grep 'Serial Number'
查看系统序列号:
dmidecode -s system-serial-number
查看内存信息:
dmidecode -t memory
查看OEM信息:
dmidecode -t
关于 Dmidecode 的更多用法,你可以通过指定 -h 选项查询。
Dmidecode的更多相关文章
- 使用 python 获取 Linux 系统信息(通过dmidecode命令)
通过 dmidecode 命令可以获取到 Linux 系统的包括 BIOS. CPU.内存等系统的硬件信息,这里使用 python 代码来通过调用 dmidecode 命令来获取 Linux 必要的系 ...
- dmidecode常用参数
dmidecode常用参数详解 作者:尹正杰 版权声明:原创作品,谢绝转载!否则将追究法律责任. dmidecode这个命令真是神器啊,他能快速的获取服务器的硬件信息,而且这个命令有很多的花式玩法,今 ...
- dmidecode查看设备硬件信息
在bash里输入:dmidecode -s system-product-name 或者lshw -class system 在Linux系统环境下(CentOS .4和Ubuntu .04已确认), ...
- linux包之dmidecode
http://www.dmtf.org/standards/smbios Dmidecode 这款软件允许你在 Linux 系统下获取有关硬件方面的信息.Dmidecode 遵循 SMBIOS/DMI ...
- 【转】dmidecode命令详解
Dmidecode 这款软件允许你在 Linux 系统下获取有关硬件方面的信息.Dmidecode 遵循 SMBIOS/DMI 标准,其输出的信息包括 BIOS.系统.主板.处理器.内存.缓存等等. ...
- CentOS(Linux)下安装dmidecode包
安装代码: yum install dmidecode 安装完成后,查看总体信息: dmidecode 查看服务器类型,测试环境为DELL R610: dmidecode -s system-prod ...
- python学习:Dmidecode系统信息(一)
#!/usr/bin/env python from subprocess import Popen, PIPE p = Popen(['dmidecode'], stdout=PIPE) d ...
- dmidecode的Python解析
#!/usr/bin/env python # -*- coding: utf-8 -*- """ 解析dmidecode命令输出结果,返回JSON格式数据 测试服务器D ...
- linux查看硬件详细信息dmidecode
[root@zabbix_server src]# dmidecode|more # dmidecode 2.12 SMBIOS 2.7 present. structures occupying b ...
- 使用 dmidecode 查看Linux服务器信息
使用 dmidecode 查看Linux服务器信息 来源 http://www.laozuo.org/6682.html 对于大部分普通服务器用户来说,我们选择VPS.服务器产品的时候比较关心的是产 ...
随机推荐
- FX Composer VS RenderMonkey 【转】
http://blog.csdn.net/debugconsole/article/details/50905398 FX COMPOSER 其实编辑一个shader到debug它,有很多方法,很多方 ...
- How to simplify a PHP code with the help of the façade pattern?
原文:https://phpenthusiast.com/blog/simplify-your-php-code-with-facade-class ------------------------- ...
- 绝对让你理解Android中的Context
这个问题是StackOverFlow上面一个热门的问题What is Context in Android? 整理这篇文章的目的是Context确实是一个非常抽象的东西.我们在项目中随手都会用到它,但 ...
- MoveSessionRestore.bat for firefox
move "c:\Documents and Settings\leon\Application Data\Mozilla\Firefox\Profiles\eyr6cp34.default ...
- arduino小车入门教学——第三天(arduino基础)
大家好,我是小编, 记上一节内容点击打开链接 我们今天讲arduino基础. 首先在arduino官网上下载程序. Windows解压版 苹果系统的版本号 好,下载过编程软件.我们就来讲编程. 这是类 ...
- ubuntu14.04 配置tomcat8
ubuntu下配置tomcat的过程事实上和windows是差点儿相同的,以下一起来看一下怎样在ubuntu14.04中配置tomcat. 1.下载tomcat 地址:http://tomcat.ap ...
- win8 推送通知 小记
http://blog.csdn.net/nacl025/article/details/8998552 http://blog.csdn.net/nacl025/article/details/90 ...
- 【Android进阶】怎样使用文件来保存程序中的数据
在程序中.有非常多保存和获取数据的方法,本篇文章,主要介绍使用文件系统对程序中的数据进行保存和读取的操作 我直接写了一个帮助类,进行文件的写入和读取操作 /** * 用于在文件里保存程序数据 * * ...
- C语言-Makefile经典教程(掌握这些足够)
makefile很重要 什么是makefile? 或许很多Winodws的程序员都不知道这个东西,因为那些Windows的IDE都为你做了这个工作,但我觉得要作一个好的和professional 的 ...
- rsync for windows 详细使用教程
rsync for windows 详细使用教程内容简介:rsync在windows与windows服务器之间的同步设置 1.准备两台机器: server-----192.168.0.201 clie ...