redhat

How To Get Computer Serial Number Using CMD Line in Linux

DMIDECODE
Use dmidecode command. If it’s not on the system, install it first.

yum install dmidecode

Now that it’s installed, run it.

dmidecode -t system

Output Example

SMBIOS 2.3 present.

Handle 0x0100, DMI type 1, 25 bytes.
System Information
Manufacturer: HP
Product Name: ProLiant DL380 G4
Version: Not Specified
Serial Number: XXXXXXXXXXX
UUID: XXXXXXX-XXXXX-XXXXXXX-XXXXXXXX-XXXXXXXX
Wake-up Type: Power Switch

Handle 0x2000, DMI type 32, 11 bytes.
System Boot Information
Status: No errors detected

Variations to use instead of "system":

bios
system
baseboard
chassis
processor
memory
cache
connector
slot
Posted in Linux SysAdmin and tagged , , , , , .

Leave a Reply

Your email address will not be published. Required fields are marked *


*