RHEL Help Red Hat Enterprise Linux Tutorials


19
Aug/09
0

Retrieving Hard Drive Info Via Command Line

It's possible find the make, model and serial number of the hard drive(s) in a RHEL or CentOS system without having physical access to the machine. Simply type the following command as root:

smartctl -i /dev/sda

The output will look something like this:

=== START OF INFORMATION SECTION ===
Model Family:     Western Digital Caviar Second Generation Serial ATA family
Device Model:     WDC WD3200AAJS-00L7A0
Serial Number:    WD-WCAV28394729
Firmware Version: 01.03E01
User Capacity:    320,072,933,376 bytes
Device is:        In smartctl database [for details use: -P show]
ATA Version is:   8
ATA Standard is:  Exact ATA specification draft version not indicated
Local Time is:    Wed Aug 19 17:58:23 2009 EDT
SMART support is: Available - device has SMART capability.
SMART support is: Enabled

In the above example, we are using /dev/sda. If you have multiple drives, you will need to run the smartctl command for each drive separately. You can get a list of all drives by running the following command as root:

fdisk -l | grep Disk

The output will look something like this:

Disk /dev/sda: 320.0 GB, 320072933376 bytes
Disk /dev/sdb: 320.0 GB, 320072933376 bytes
Disk /dev/sdc: 163.9 GB, 163928604672 bytes

For more information on smartctl, check out the man page.

Author: Zak

RHELHelp.com Founder and Lead Editor
Comments (0) Trackbacks (0)

No comments yet.

Leave a comment


No trackbacks yet.