Wise people learn when they can; fools learn when they must - Arthur Wellesley

Wednesday, 22 February 2017

RHEL-6 (3) KNOW YOUR SYSTEM-P3 (DMIDECODE)


RHEL-6 (3)
              KNOW YOUR SYSTEM-P3


How to know about all hardware info of my system in one go?
How to find Server Manufacturer, Model Number, Serial Number?
How to find Processor Information?
How to find Memory information?
How to find Internal Expansion slots information?
How to find the BIOS version?
What is the maximum RAM size supported by the system?
How much RAm system is using?
How to find the available memory slots for expansion?
How to find the serial number without using dmidecode?
Biosdecode

DMIDECODE:

dmidecode is a tool for dumping a computer's DMI (some say SMBIOS ) table contents in a human-readable format. This table contains a description of the system's hardware components, as well as other useful pieces of information.

Dmidecode does not scan system hardware; it only reports what is told by BIOS to it.

The Desktop Management Interface (DMI) generates a standard framework for managing and tracking components in a desktop, notebook or server components, by abstracting these components from the software that manages them. Modern mother boards are compatible with this standard. For a lay user it means that the BIOS settings can be watched from your OS. DMI standards are published by Distributed Management Task Force (DMTF) into desktop-management standards. They also provide a related standard named SMBIOS (System Management BIOS).

Remember 2 things “--strings" (-s) and “--type" (-t) with dmidecode.

[root@rhel6-server ~]# dmidecode

[root@rhel6-server ~]# dmidecode --help
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
 -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

[root@rhel6-server ~]# dmidecode --t
dmidecode: option '--type' requires an argument
Type number or keyword expected
Valid type keywords are:
  bios
  system
  baseboard
  chassis
  processor
  memory
  cache
  connector
  slot

These are available keywords for type.

[root@rhel6-server ~]# dmidecode --string
dmidecode: option '--string' requires an argument
String keyword expected
Valid string keywords are:
  bios-vendor
  bios-version
  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

These are available keywords for Strings.

FOR TYPES, we can…

[root@rhel6-server ~]# dmidecode -t bios
# dmidecode 2.11
SMBIOS 2.4 present.

Handle 0x0000, DMI type 0, 24 bytes
BIOS Information
        Vendor: Phoenix Technologies LTD
        Version: 6.00
        Release Date: 06/02/2011
        Address: 0xEA170
        Runtime Size: 89744 bytes
        ROM Size: 64 kB
        Characteristics:
                ISA is supported
================O/P REMOVED=============================

[root@rhel6-server ~]# dmidecode -t system
# dmidecode 2.11
SMBIOS 2.4 present.

Handle 0x0001, DMI type 1, 27 bytes
System Information
        Manufacturer: VMware, Inc.
        Product Name: VMware Virtual Platform
        Version: None
        Serial Number: VMware-56 4e 38 07 df 5e f7 ea-a3 e5 e9 9f 50 90 4f 22
        UUID: 564D380D-DF5E-F1EA-A3E5-E99F09804E36
        Wake-up Type: Power Switch
        SKU Number: Not Specified
================O/P REMOVED=============================

Similarly we can find the HW info regarding….

[root@rhel6-server ~]# dmidecode -t baseboard
[root@rhel6-server ~]# dmidecode -t chassis
[root@rhel6-server ~]# dmidecode -t processor
[root@rhel6-server ~]# dmidecode -t memory
[root@rhel6-server ~]# dmidecode -t cache
[root@rhel6-server ~]# dmidecode -t connector
[root@rhel6-server ~]# dmidecode -t slot

We can also use it by type no.

Type   Information
       ----------------------------------------
          0   BIOS
          1   System
          2   Base Board
          3   Chassis
          4   Processor
          5   Memory Controller
          6   Memory Module
          7   Cache
          8   Port Connector
          9   System Slots
         10   On Board Devices
         11   OEM Strings
         12   System Configuration Options
         13   BIOS Language
         14   Group Associations
         15   System Event Log
         16   Physical Memory Array
         17   Memory Device
         18   32-bit Memory Error
         19   Memory Array Mapped Address
         20   Memory Device Mapped Address
         21   Built-in Pointing Device
         22   Portable Battery
         23   System Reset
         24   Hardware Security
         25   System Power Controls
         26   Voltage Probe
         27   Cooling Device
         28   Temperature Probe
         29   Electrical Current Probe
         30   Out-of-band Remote Access
         31   Boot Integrity Services
         32   System Boot
         33   64-bit Memory Error
         34   Management Device
         35   Management Device Component
         36   Management Device Threshold Data
         37   Memory Channel
         38   IPMI Device
         39   Power Supply

Each keyword is equivalent to a list of type numbers:

       Keyword     Types
       ------------------------------
       bios        0, 13
       system      1, 12, 15, 23, 32
       baseboard   2, 10
       chassis     3
       processor   4
       memory      5, 6, 16, 17
       cache       7
       connector   8
       slot        9

[root@rhel6-server ~]# dmidecode -t 0
[root@rhel6-server ~]# dmidecode -t 5
[root@rhel6-server ~]# dmidecode -t 9

We can use “Strings” (-s) for more precise info.

List of strings can be found by,

[root@rhel6-server ~]# dmidecode --string

[root@rhel6-server ~]# dmidecode -t system |grep -i serial
Serial Number: VMware-56 4e 38 07 df 5e f7 ea-a3 e5 e9 9f 50 90 4f 22

[root@rhel6-server ~]# dmidecode -s system-serial-number
VMware-56 4e 38 07 df 5e f7 ea-a3 e5 e9 9f 50 90 4f 22

[root@rhel6-server ~]# dmidecode -s processor-manufacturer |uniq
GenuineIntel
000000000000

[root@rhel6-server ~]# dmidecode -t processor |grep -i manufacturer |uniq
        Manufacturer: GenuineIntel
        Manufacturer: 000000000000

WHAT IF SOMEHOW I AM UNABLE TO USE “DMIDECODE”………??

Check this………JJJ

[root@rhel6-server ~]# ls -l /sys/devices/virtual/dmi/id/

[root@rhel6-server ~]# cat /sys/devices/virtual/dmi/id/product_serial
VMware-56 4d 38 0d df 5e f1 ea-a3 e5 e9 9f 09 80 4e 36

[root@rhel6-server ~]# cat /sys/devices/virtual/dmi/id/sys_vendor
VMware, Inc.

[root@rhel6-server ~]# cat /sys/devices/virtual/dmi/id/bios_vendor
Phoenix Technologies LTD

[root@rhel6-server ~]# cat /sys/devices/virtual/dmi/id/board_vendor
Intel Corporation

[root@rhel6-server ~]# cat /sys/devices/virtual/dmi/id/chassis_vendor
No Enclosure

[root@rhel6-server ~]# cat /sys/devices/virtual/dmi/id/sys_vendor
VMware, Inc.

BIOSDECODE:

It is a command line utility to parses the BIOS memory and prints information about all structures (or entry points) it knows of. It finds out information about hardware such as:

IPMI Device
Type of memory and speed
Chassis Information
Temperature Probe
Cooling Device
Electrical Current Probe
Processor and Memory Information
Serial numbers
BIOS version
PCI / PCIe Slots and Speed
etc.

Things to consider:

·         biosdecode parses the BIOS memory and prints the information about all structures.
·         Decoding BIOS data is the same as dumping a computer's DMI. The DMI table mainly describes what the system is currently made of.
·         Data provided by biosdecode is not in a human-readable format.

[root@rhel6-server ~]# biosdecode --help
Usage: biosdecode [OPTIONS]
Options are:
 -d, --dev-mem FILE     Read memory from device FILE (default: /dev/mem)
 -h, --help             Display this help text and exit
 -V, --version          Display the version and exit

[root@rhel6-server ~]# biosdecode
# biosdecode 2.11
SMBIOS 2.4 present.
        Structure Table Length: 15494 bytes
        Structure Table Address: 0x000E0010
        Number Of Structures: 364
        Maximum Structure Size: 98 bytes
BIOS32 Service Directory present.
        Revision: 0
        Calling Interface Address: 0x000FD780
ACPI 2.0 present.
        OEM Identifier: PTLTD
        RSD Table 32-bit Address: 0x3FEEECB8
        XSD Table 64-bit Address: 0x000000003FEEEC5C
PNP BIOS 1.0 present.
        Event Notification: Not Supported
        Real Mode 16-bit Code Address: F000:9614
        Real Mode 16-bit Data Address: 0040:0000
        16-bit Protected Mode Code Address: 0x000F9632
        16-bit Protected Mode Data Address: 0x00000400
================O/P REMOVED=============================



Data provided by biosdecode is not in a human-readable format. You need to use dmidecode command for dumping  DMI (SMBIOS) table contents on screen. 

No comments:

Post a Comment