Explore System Hardware Information with sys-apps/dmidecode
Discover comprehensive insights into your system's hardware configuration using dmidecode, a powerful utility that retrieves data from the Desktop Management Interface (DMI) of your computer's BIOS. From RAM speed to BIOS details, processor specifications to memory configurations, dmidecode empowers you to delve deep into the intricacies of your system's components.
Available options for dmidecode by using --string
| Keyword | Description |
|---|---|
| dmidecode -s bios-vendor | The vendor responsible for manufacturing the system's BIOS firmware. |
| dmidecode -s bios-version | The specific release or version number assigned to the system's BIOS firmware. |
| dmidecode -s bios-release-date | The date when the system's BIOS firmware was initially released or made available. |
| dmidecode -s bios-revision | The specific revision number assigned to the system's BIOS firmware. |
| dmidecode -s firmware-revision | The specific version or revision number assigned to the system's firmware, including the BIOS. |
| dmidecode -s system-manufacturer | The manufacturer responsible for producing the system. |
| dmidecode -s system-product-name | The specific model or product name assigned to the system by the manufacturer. |
| dmidecode -s system-version | The specific release or version number assigned to the system. |
| dmidecode -s system-serial-number | The unique serial number assigned to the system by the manufacturer. |
| dmidecode -s system-uuid | The Universally Unique Identifier (UUID) assigned to the system, providing a globally unique identifier. |
| dmidecode -s system-sku-number | The Stock Keeping Unit (SKU) number used for product and inventory tracking. |
| dmidecode -s system-family | The family or product line the system belongs to. |
| dmidecode -s baseboard-manufacturer | The manufacturer responsible for producing the motherboard or baseboard. |
| dmidecode -s baseboard-product-name | The specific model or product name of the motherboard or baseboard. |
| dmidecode -s baseboard-version | The release or version number assigned to the motherboard or baseboard. |
| dmidecode -s baseboard-serial-number | The unique serial number assigned to the motherboard or baseboard. |
| dmidecode -s baseboard-asset-tag | The asset tag assigned to the motherboard for tracking or identification. |
| dmidecode -s chassis-manufacturer | The manufacturer responsible for producing the system chassis. |
| dmidecode -s chassis-type | The chassis form factor, such as tower, rack-mount, or desktop. |
| dmidecode -s chassis-version | The specific release or version number assigned to the chassis. |
| dmidecode -s chassis-serial-number | The unique serial number assigned to the chassis. |
| dmidecode -s chassis-asset-tag | The asset tag assigned to the chassis for tracking or identification. |
| dmidecode -s processor-family | The processor family or category, indicating architectural lineage. |
| dmidecode -s processor-manufacturer | The manufacturer responsible for producing the processor. |
| dmidecode -s processor-version | The specific release or version number assigned to the processor. |
| dmidecode -s processor-frequency | The operating frequency or speed of the processor, typically measured in gigahertz (GHz). |
Available options for dmidecode by using --type
| Type | Information |
|---|---|
| dmidecode –type 0 | BIOS |
| dmidecode –type 1 | System |
| dmidecode –type 2 | Base Board |
| dmidecode –type 3 | Chassis |
| dmidecode –type 4 | Processor |
| dmidecode –type 5 | Memory Controller |
| dmidecode –type 6 | Memory Module |
| dmidecode –type 7 | Cache |
| dmidecode –type 8 | Port Connector |
| dmidecode –type 9 | System Slots |
| dmidecode –type 11 | OEM Strings |
| dmidecode –type 13 | BIOS Language |
| dmidecode –type 15 | System Event Log |
| dmidecode –type 16 | Physical Memory Array |
| dmidecode –type 17 | Memory Device |
| dmidecode –type 18 | 32-bit Memory Error |
| dmidecode –type 19 | Memory Array Mapped Address |
| dmidecode –type 20 | Memory Device Mapped Address |
| dmidecode –type 21 | Built-in Pointing Device |
| dmidecode –type 22 | Portable Battery |
| dmidecode –type 23 | System Reset |
| dmidecode –type 24 | Hardware Security |
| dmidecode –type 25 | System Power Controls |
| dmidecode –type 26 | Voltage Probe |
| dmidecode –type 27 | Cooling Device |
| dmidecode –type 28 | Temperature Probe |
| dmidecode –type 29 | Electrical Current Probe |
| dmidecode –type 30 | Out-of-band Remote Access |
| dmidecode –type 31 | Boot Integrity Services |
| dmidecode –type 32 | System Boot |
| dmidecode –type 34 | Management Device |
| dmidecode –type 35 | Management Device Component |
| dmidecode –type 36 | Management Device Threshold Data |
| dmidecode –type 37 | Memory Channel |
| dmidecode –type 38 | IPMI Device |
| dmidecode –type 39 | Power Supply |
Install dmidecode
emerge -a sys-apps/dmidecode
pacman -S dmidecode
apt install dmidecode
yum install dmidecode
Print current ram speed
dmidecode | perl -lne 'print $1 if /Current\s+Speed:\s+(\d+\s+MHz)/
Print bios info
dmidecode -t bios
Print system info
dmidecode -t system
Print baseboard info
dmidecode -t baseboard
Print chassis info
dmidecode -t chassis
Print processor info
dmidecode -t processor
Print memory info
dmidecode -t memory
Print cache info
dmidecode -t cache
Print connector info
dmidecode -t connector
Print slot info
dmidecode -t slot
Show more details of ram-memory
dmidecode --type memory
Available String Options
System strings
dmidecode -s system-manufacturer
dmidecode -s system-product-name
dmidecode -s system-version
dmidecode -s system-serial-number
dmidecode -s system-uuid
BIOS strings
dmidecode -s bios-vendor
dmidecode -s bios-version
dmidecode -s bios-release-date
Baseboard strings
dmidecode -s baseboard-manufacturer
dmidecode -s baseboard-product-name
dmidecode -s baseboard-version
dmidecode -s baseboard-serial-number
Chassis strings
dmidecode -s chassis-manufacturer
dmidecode -s chassis-type
dmidecode -s chassis-version
dmidecode -s chassis-serial-number
Processor strings
dmidecode -s processor-family
dmidecode -s processor-manufacturer
dmidecode -s processor-version
dmidecode -s processor-frequency
Output Options
- Formatting Options
Quiet output (suppress headers)
dmidecode -q -t system
No piping warning
dmidecode --no-sysfs -t memory
Dump raw DMI data
dmidecode --dump-bin dmi.bin
Read from binary dump
dmidecode --from-dump d
Check what´s available without being root
dmidecode 2>/dev/null || echo "Root access required for complete information"
Show all information about system
dmidecode
Motherboard Information
dmidecode -t baseboard | awk -F: '
/Manufacturer:/ {print "Motherboard Manufacturer:" $2}
/Product Name:/ {print "Motherboard Model:" $2}
/Version:/ {print "Motherboard Version:" $2}
/Serial Number:/{print "Motherboard Serial:" $2}
'
Memory Details
dmidecode -t 17 | grep -E "(Size|Speed|Manufacturer|Part Number)" | grep -v "No Module"
Total installed ram memory in megabyte
dmidecode -t 17 | grep "Size:" | grep -v "No Module" | awk '{sum+=$2} END {print sum " MB"}'
Maximum memory capacity
dmidecode -t 16 | grep "Maximum Capacity"
CPU Information
dmidecode -t processor | grep -E "(Version|Family|Max Speed|Current Speed|Core Count|Thread Count)"
Sanitize Output
dmidecode "$@" | sed 's/Serial Number:.*/Serial Number: [REDACTED]/'
Get license info
get_license_info() {
u=$(dmidecode -s system-uuid); b=$(dmidecode -s baseboard-serial-number)
printf "UUID: %s\nSerial: %s\nManufacturer: %s\nModel: %s\nFingerprint: %s\n" \
"$u" "$(dmidecode -s system-serial-number)" "$(dmidecode -s system-manufacturer)" \
"$(dmidecode -s system-product-name)" "$(printf %s "$u$b" | sha256sum | cut -d' ' -f1)"
}
get_license_info
Tips and Tricks
Print Serial Number
dmidecode | grep "Serial Number" | head -n1
Show maximum capacity of ram-memory
dmidecode | grep "Max" | head -n1
Show speed of ram-memory
dmidecode --type memory | grep -i "speed"
See your current RAM frequency
dmidecode -t 17 | awk -F":" '/Speed/ { print $2 }'
Detect if we are running on a VMware virtual machine
dmidecode | awk '/VMware Virtual Platform/ {print $3,$4,$5}'
See your current RAM frequency
dmidecode | grep -i "current speed"
Determine whether a CPU has 64 bit capability or not
dmidecode --type=processor | grep -i -A 1 charac
Check motherboard manufacturer, product name, version and serial number
dmidecode | grep -i 'Base Board Information' -A4 -B1
Get info on RAM Slots and Max RAM
dmidecode 2.9 | grep "Maximum Capacity"; dmidecode -t 17 | grep Size
Get current speed of cpu in use and totaly cpu mhz
awk -F": " '/cpu MHz\ */ { print "Processor (or core) running speed is: " $2 }' /proc/cpuinfo
dmidecode | awk -F':[[:space:]]*' '/Current Speed/ { print "Processor real speed is: " $2 }'
Map the slot of an I/O card to its PCI bus address
dmidecode --type 9 |egrep 'Bus Address|Designation'
Another way to print cpu max speed
dmidecode | awk -F':[[:space:]]*' '
/Processor Information/ { in_cpu = 1 }
in_cpu && $1 ~ /Current Speed/ {
print "Processor real speed is:", $2
in_cpu = 0
}
'
Inspect kernel logs for HP WMI / hwmon / chassis intrusion support
dmesg | grep -iE 'hwmon|hp|wmi|intrusion' | tail -n 80
Print how much ram memory we got and how many memory cards we use
dmidecode -t 17 | grep "Size:" | grep -v "No Module"
Print memory ddr type we got in use
dmidecode -t 17|grep -wi 'Type:'|sed 's/\t//g'
Print bios release date
midecode -s bios-release-date d
Bonus
You can retrieve the platform type (system product name) by reading the file
cat /sys/class/dmi/id/product_name
You can obtain the BIOS version by reading
cat /sys/class/dmi/id/bios_version
To retrieve the amount of physical memory, you can make use of the following command
cat /sys/class/dmi/id/memory/size