Using Dmidecode : Getting BIOS information and other hardware information

Using Dmidecode
Introduction: 

How to get the BIOS information . Earlier , myself and probably many people used to go BIOS to get the BIOS version and retrieving information regarding hardware :). What if the machine is a production host . We cannot shutdown the host to get the BIOS information . In such type of a situation, the dmidecode tool comes handy. It is a command line tool and can be freely used as it is released under General Public Licence (GPL).


About Dmidecode:

 
Dmidecode will report  information regarding your system's hardware as described in the system's BIOS . It will give information like your BIOS version, BIOS vendor , CPU information , System Board information and other hardware information. Please note that we cannot always reliably believe in the results of dmidecode as dmidecode does not scan your hardware and simply collects the information from the BIOS.

Using Dmidecode:

 
Like various other unix tools , dmidecode is also a command-line utility.It has few options , so anybody can learn it quickly . We will see here in this post , few examples below to retrieve information about our hardware . To use dmidecode , just type dmidecode in the terminal . It will give all information  the hardware. We will see now various other useful options of dmideocde and their corresponding results. These commands are executed on my HP Desktop computer running RHEL 3.

To get the BIOS information:

-bash-3.2$ sudo dmidecode --type=bios
Password:
# dmidecode 2.9
SMBIOS 2.5 present.

Handle 0x0001, DMI type 0, 24 bytes
BIOS Information
Vendor: Hewlett-Packard
Version: 786F2 v01.04
Release Date: 01/31/2008
Address: 0xE0000
Runtime Size: 128 kB
ROM Size: 4096 kB
Characteristics:
PCI is supported
PNP is supported
BIOS is upgradeable
BIOS shadowing is allowed
Boot from CD is supported
Selectable boot is supported
EDD is supported
Japanese floppy for Toshiba 1.2 MB is supported (int 13h)
3.5"/720 KB floppy services are supported (int 13h)
Print screen service is supported (int 5h)
8042 keyboard services are supported (int 9h)
Serial services are supported (int 14h)
Printer services are supported (int 17h)
ACPI is supported
USB legacy is supported
LS-120 boot is supported
ATAPI Zip drive boot is supported
BIOS boot specification is supported
Function key-initiated network boot is supported
Targeted content distribution is supported
BIOS Revision: 1.4

Handle 0x0030, DMI type 13, 22 bytes
BIOS Language Information
Installable Languages: 1
en|US|iso8859-1
Currently Installed Language: en|US|iso8859-1

$$ To get BIOS version and vendor .

$ sudo dmidecode|grep -B 2 -i 'release date'
Vendor: Hewlett-Packard
Version: 786F2 v01.04
Release Date: 01/31/2008


$$ To get information regarding the processor.

-bash-3.2$ sudo dmidecode --type=processor
# dmidecode 2.9
SMBIOS 2.5 present.

Handle 0x0005, DMI type 4, 40 bytes
Processor Information
Socket Designation: XU1 PROCESSOR
Type: Central Processor
Family: Pentium 4
Manufacturer: Intel
ID: 76 06 01 00 FF FB EB BF
Signature: Type 0, Family 6, Model 23, Stepping 6
Flags:
FPU (Floating-point unit on-chip)
VME (Virtual mode extension)
DE (Debugging extension)
PSE (Page size extension)
TSC (Time stamp counter)
MSR (Model specific registers)
PAE (Physical address extension)
MCE (Machine check exception)
CX8 (CMPXCHG8 instruction supported)
APIC (On-chip APIC hardware supported)
SEP (Fast system call)
MTRR (Memory type range registers)
PGE (Page global enable)
MCA (Machine check architecture)
CMOV (Conditional move instruction supported)
PAT (Page attribute table)
PSE-36 (36-bit page size extension)
CLFSH (CLFLUSH instruction supported)
DS (Debug store)
ACPI (ACPI supported)
MMX (MMX technology supported)
FXSR (Fast floating-point save and restore)
SSE (Streaming SIMD extensions)
SSE2 (Streaming SIMD extensions 2)
SS (Self-snoop)
HTT (Hyper-threading technology)
TM (Thermal monitor supported)
PBE (Pending break enabled)
Version: Intel(R) Core(TM)2 Duo CPU     E8400  @ 3.00GHz
Voltage: 1.2 V
External Clock: 1333 MHz
Max Speed: 6000 MHz
Current Speed: 3000 MHz
Status: Populated, Enabled
Upgrade: Socket LGA775
L1 Cache Handle: 0x0006
L2 Cache Handle: 0x0007
L3 Cache Handle: 0x0008
Serial Number: Not Specified
Asset Tag: Not Specified
Part Number: Not Specified
Core Count: 2
Core Enabled: 2
Thread Count: 2
Characteristics:
64-bit capable

Alternatively , we can get the CPU information by reading the `/proc/cpuinfo' file .


$$ To get information regarding memory type and maximum supported memory.

-bash-3.2$ sudo dmidecode --type=memory | egrep  "Maximum|Type"
Error Correction Type: Multi-bit ECC
Maximum Capacity: 16 GB
Type: DDR2
Type Detail: Synchronous
Type: DDR2
Type Detail: Synchronous
Type: DDR2
Type Detail: Synchronous
Type: DDR2
Type Detail: Synchronous
Type: DDR2
Type Detail: Synchronous
Type: DDR2
Type Detail: Synchronous


$$ To know about the various other keywords supported by dmidecode  , use the -t option with dmidecode

-bash-3.2$ dmidecode -t


The Valid type keywords are:
bios                :  Will give BIOS related information
system            :  Will give system related information
baseboard      :  Will give system board related information
chassis           :  Will give chassis information
processor      :   Will give CPU related information
memory        :   Will give memory related information
cache            :   Will give cache memory related information like L1 and L2 cache
connector     :   Will give you information regarding various hardware ports available in your
                         computer like Network , Mouse , Keyboard Port etc.
slot               :   Will give  information regarding system slots
 

Conclusion :

Thus , we have seen using the dmidecode utility . Like every other GNU tool is useful for a particular purpose , dmidecode helps us in getting useful  information about our hardware. The tool is available for download from http://www.nongnu.org/dmidecode/



Comments

Popular posts from this blog

PSSH : Parallel SSH to execute commands on a number of hosts

How to add check_http as a service in Nagios Monitoring using NRPE

Configuring Nagios to monitor services using NRPE