How To Check Detailed Hard Drive Information in Linux

SumodirjoDIY, Open Source, Tutorial

Sometimes we need to know hard drive information detail including Model Number, Serial Number and Firmware Revision. How to do it? Check on the physical drive one by one, the information is printed on top of the hard drive. If it’s your PC on your house it’s easy, but what if it’s a server on a datacenter located in a different continent? you can use hdparm -I to do this.

If you cannot find this command, you can install it first. In Ubuntu you can use command below

$ sudo apt-get update
$ sudo apt-get install hdparm

If you are using Red Hat / CentOS / Fedora you can use command below :

# yum check-update
# yum install hdparm

Command that we have to enter to see hard drive detail:

# hdparm -IFor example, if we want to check first IDE drive (/dev/hda), we can use command below:
[root@sissy ~]# hdparm -I /dev/hda

/dev/hda:

ATA device, with non-removable media
        Model Number:       WDC WD800BB-22JHC0
        Serial Number:      WD-WCAM9D788248
        Firmware Revision:  05.01C05
Standards:
        Supported: 6 5 4
        Likely used: 6
Configuration:
        Logical         max     current
        cylinders       16383   16383
        heads           16      16
        sectors/track   63      63
        --
        CHS current addressable sectors:   16514064
        LBA    user addressable sectors:  156301488
        device size with M = 1024*1024:       76319 MBytes
        device size with M = 1000*1000:       80026 MBytes (80 GB)
Capabilities:
        LBA, IORDY(can be disabled)
        Standby timer values: spec'd by Standard, with device specific minimum
        R/W multiple sector transfer: Max = 16  Current = 16
        Recommended acoustic management value: 128, current value: 254
        DMA: mdma0 mdma1 mdma2 udma0 udma1 udma2 udma3 udma4 *udma5
             Cycle time: min=120ns recommended=120ns
        PIO: pio0 pio1 pio2 pio3 pio4
             Cycle time: no flow control=120ns  IORDY flow control=120ns
Commands/features:
        Enabled Supported:
           *    SMART feature set
           *    Power Management feature set
           *    Write cache
           *    Look-ahead
           *    Host Protected Area feature set
           *    WRITE_BUFFER command
           *    READ_BUFFER command
           *    DOWNLOAD_MICROCODE
                SET_MAX security extension
                Automatic Acoustic Management feature set
           *    Device Configuration Overlay feature set
           *    Mandatory FLUSH_CACHE
           *    SMART error logging
           *    SMART self-test
HW reset results:
        CBLID- above Vih
        Device num = 0 determined by the jumper
Checksum: correct

Complete enough right? It’s not a bad idea to keep notes of your device Model Number, Serial Number and Firmware Revision, especially for a drive on a server.