Introduction to dmidecode Command
In this step, we will introduce the dmidecode
command, a powerful tool for retrieving detailed hardware information on Linux systems.
The dmidecode
command is a free software that reads information about a system's hardware from the BIOS according to the SMBIOS/DMI standard. It can display a wide range of hardware information, including system manufacturer, model name, serial number, BIOS version, processor details, memory configuration, and more.
Let's start by installing the dmidecode
package:
sudo apt-get update
sudo apt-get install -y dmidecode
Now, we can use the dmidecode
command to display the system's hardware information:
sudo dmidecode
Example output:
## dmidecode 3.3
Getting SMBIOS data from sysfs.
SMBIOS 3.2.0 present.
Handle 0x0001, DMI type 1, 27 bytes
System Information
Manufacturer: VMware, Inc.
Product Name: VMware Virtual Platform
Version: None
Serial Number: VMware-42 1d 93 c1 d1 2f 2a 19-5a 1c 4f 3b 6a 4f 9a 6d
UUID: 421d93c1-d12f-2a19-5a1c-4f3b6a4f9a6d
Wake-up Type: Power Switch
SKU Number: Not Specified
Family: Virtual Machine
The output provides a wealth of information about the system's hardware, including the manufacturer, product name, serial number, UUID, and more.
We can also extract specific hardware details using the dmidecode
command. For example, to get the processor information, we can use the following command:
sudo dmidecode -t processor
Example output:
## dmidecode 3.3
Getting SMBIOS data from sysfs.
SMBIOS 3.2.0 present.
Handle 0x0003, DMI type 3, 21 bytes
Chassis Information
Manufacturer: VMware, Inc.
Type: Virtual Machine
Lock: Not Present
Version: None
Serial Number: VMware-42 1d 93 c1 d1 2f 2a 19-5a 1c 4f 3b 6a 4f 9a 6d
Asset Tag: Not Specified
Boot-up State: Safe
Power Supply State: Safe
Thermal State: Safe
Security Status: None
This command displays detailed information about the system's processor, including the manufacturer, model, speed, and other relevant details.
The dmidecode
command provides a wealth of hardware information and can be a valuable tool for system administrators and IT professionals. In the next steps, we'll explore more practical examples of using dmidecode
to retrieve specific hardware details.