How to Use dmidecode to Retrieve Detailed Linux Hardware Information
This guide explains what dmidecode does, its command syntax, option meanings, and provides practical examples for extracting BIOS, CPU, memory, and other hardware details from a Linux system.
dmidecode: Retrieve Device Hardware Information
Function Description
The dmidecode command can obtain hardware information on a Linux system, such as BIOS, system, motherboard, CPU, memory, and cache.
It decodes the DMI (Desktop Management Interface) database into readable text. Because DMI data can be manually altered, the displayed information may not always reflect the actual hardware state.
DMI is a management system for collecting computer system information, and its collection must follow the SMBIOS specification. SMBIOS defines a standard format that manufacturers use to present product management data.
DMI acts as an interface between management tools and the system layer, establishing a standardized, manageable system that simplifies hardware awareness for vendors and users. Its main component is the MIF database, which stores all information about the computer system and its components, allowing users to retrieve serial numbers, manufacturers, port details, and other accessory data.
Command Syntax
dmidecode [options]Option Meanings
-d : Read information from the device file; output is the same as the default.
-h : Show help information.
-s : Display only the specified DMI string.
-q : Show a reduced, simplified output.
-t : Display only the specified type.
-u : Show the raw, undecoded entry content.
-- -dump-bin file : Dump DMI data to a binary file.
-- -from-dump FILE : Read DMI data from a binary file.
-V : Show version information.
Reference Examples
(1) View all hardware information of the server # dmidecode (2) View server model # dmidecode | grep "Product Name" (3) View motherboard serial number # dmidecode | grep "Serial Number" (4) View system serial number # dmidecode -s system-serial-number (5) View detailed CPU information # dmidecode -t processor (6) View CPU information # dmidecode | grep CPU (7) View detailed memory information # dmidecode -t memory (8) View server system manufacturer # dmidecode -s system-manufacturer (9) View server product name (brand/model) # dmidecode -s system-product-name (10) Show undecoded raw entry content
# dmidecode -uSigned-in readers can open the original source through BestHub's protected redirect.
This article has been distilled and summarized from source material, then republished for learning and reference. If you believe it infringes your rights, please contactand we will review it promptly.
Open Source Linux
Focused on sharing Linux/Unix content, covering fundamentals, system development, network programming, automation/operations, cloud computing, and related professional knowledge.
How this landed with the community
Was this worth your time?
0 Comments
Thoughtful readers leave field notes, pushback, and hard-won operational detail here.
