Unix & Linux Stack Exchange is a question and answer site for users of Linux, FreeBSD and other Un*x-like operating systems. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

Seeing the device name by df, is it somehow possible to resolve it to the physical drive name such as vendor / type.

/dev/sda3               915.4G     34.9G    880.0G   4% /share/HDA_DATA
/dev/sdd3                 1.8T    668.1G      1.1T  36% /share/HDD_DATA

I have learnt that I find some info in sys/block, but I do not find the vendor's type name in there?

-- Added --

My system is a Linux based QNAP NAS, so things might be a little different there. For me as a non Linux expert hard to tell, what is "standard", and what not.

-- Added as of Steven's answer --

[~] # hdparm -I /dev/sdb3

 HDIO_DRIVE_CMD(identify) failed: Invalid argument
share|improve this question
Maybe you have more luck with dmesg or dmesg | grep -C10 sda. – jippie Jun 2 '12 at 18:26
Or sudo smartctl --all /dev/sda (requires root privileges). – jippie Jun 2 '12 at 18:27
The dmesg approach works, thx. Will rate your answer below as correct, and add a comment. – Horst Walter Jun 2 '12 at 22:08
Similar messages will appear in /var/log/syslog or /var/log/dmesg. Exact file name is highly dependent on distribution. – jippie Jun 2 '12 at 22:16
up vote 4 down vote accepted
sudo lshw -class disk
       description: DVD-RAM writer
       product: CDDVDW SH-S223Q
       vendor: TSSTcorp
       physical id: 0
       bus info: scsi@0:0.0.0
       logical name: /dev/cdrom
       logical name: /dev/cdrw
       logical name: /dev/dvd
       logical name: /dev/dvdrw
       logical name: /dev/sr0
       version: SB02
       capabilities: removable audio cd-r cd-rw dvd dvd-r dvd-ram
       configuration: ansiversion=5 status=ready
          physical id: 0
          logical name: /dev/cdrom
       description: ATA Disk
       product: WDC WD1600AAJS-0
       vendor: Western Digital
       physical id: 1
       bus info: scsi@1:0.0.0
       logical name: /dev/sda
       version: 01.0
       serial: WD-WMAV2P964464
       size: 149GiB (160GB)
       capabilities: partitioned partitioned:dos
       configuration: ansiversion=5 signature=000c0805
       description: SCSI Disk
       physical id: 0.0.0
       bus info: scsi@6:0.0.0
       logical name: /dev/sdb
       size: 931GiB (1TB)
       capabilities: partitioned partitioned:dos
       configuration: signature=a39eabc7
share|improve this answer
On my QNAP NAS I do not find this lshw command. Checked /sbin /usr/sbin Any idea where else I could find it? I believe you this is working, unfortunately not on my Linux based NAS. – Horst Walter Jun 2 '12 at 17:54
I am using the dmesg approach, as in jippie's comment above. Will rate this as answer anyway, since it is correct. – Horst Walter Jun 2 '12 at 22:10

The QNAP NAS products run firmware that is essentially a custom Linux distro. It is quite spartan, with a minimal set of command line tools (and many of those provided by busybox). Fortunately, there is a decent implementation of hdparm in there, so you should be able to query a drive, as follows:

hdparm -I /dev/sda

Here's the output I get from a "QNAP TS-239 Pro NAS" with a "Western Digital RE4 1TB" drive (output is verbatim, except for the drive's serial number, which I have purposely obscured):


ATA device, with non-removable media
    Model Number:       WDC WD1003FBYX-01Y7B0                   
    Serial Number:      AB-CDEF01234567
    Firmware Revision:  01.01V01
    Supported: 8 7 6 5 
    Likely used: 8
    Logical     max current
    cylinders   16383   16383
    heads       16  16
    sectors/track   63  63
    CHS current addressable sectors:   16514064
    LBA    user addressable sectors:  268435455
    LBA48  user addressable sectors: 1953525168
    device size with M = 1024*1024:      953869 MBytes
    device size with M = 1000*1000:     1000204 MBytes (1000 GB)
    LBA, IORDY(can be disabled)
    Queue depth: 32
    Standby timer values: spec'd by Standard, with device specific minimum
    R/W multiple sector transfer: Max = 16  Current = 0
    Advanced power management level: unknown setting (0x0080)
    Recommended acoustic management value: 128, current value: 254
    DMA: mdma0 mdma1 mdma2 udma0 udma1 udma2 udma3 udma4 udma5 *udma6 
         Cycle time: min=120ns recommended=120ns
    PIO: pio0 pio1 pio2 pio3 pio4 
         Cycle time: no flow control=120ns  IORDY flow control=120ns
    Enabled Supported:
       *    NOP cmd
       *    READ BUFFER cmd
       *    WRITE BUFFER cmd
       *    Host Protected Area feature set
       *    Look-ahead
       *    Write cache
       *    Power Management feature set
            Security Mode feature set
       *    SMART feature set
       *    FLUSH CACHE EXT command
       *    Mandatory FLUSH CACHE command 
       *    Device Configuration Overlay feature set 
       *    48-bit Address feature set 
       *    Automatic Acoustic Management feature set 
            SET MAX security extension
       *    SET FEATURES subcommand required to spinup after power up
            Power-Up In Standby feature set
       *    Advanced Power Management feature set
       *    DOWNLOAD MICROCODE cmd
       *    General Purpose Logging feature set
       *    SMART self-test 
       *    SMART error logging 
    Master password revision code = 65534
    not enabled
    not locked
    not frozen
    not expired: security count
        supported: enhanced erase
Checksum: correct

"Vendor" and "Type" are not explicitly reported by hdparm. However, "Model Number" is reported, and a quick web search on it should yield anything you need to know about a drive.

share|improve this answer
Sounds good, in my case I do get the following response: HDIO_DRIVE_CMD(identify) failed: Invalid argument Have updated question. – Horst Walter Jun 2 '12 at 23:31
@Horst: Try hdparm -I /dev/sdb instead. /dev/sdb3 is most likely not a drive, but a partition, and hdparm needs a drive. – Steven Monday Jun 3 '12 at 2:06
Thanks for the hint, but no luck. I have tried sda, sdb, sdb3, sda3 etc, all the same issue HDIO_DRIVE_CMD(identify) failed: Invalid argument Run it as admin, which should be root on QNAP, sudo I cannot find (tried sudo hdparm ...) – Horst Walter Jun 3 '12 at 8:50

Most modern Linux systems use udev to manage devices. This isn't the case on all embedded devices though; I don't know whether this specific device uses udev.

udevadm info -n /dev/sda3 -a
udevadm info -n /dev/sda3 -q property

will print everything the system knows about /dev/sda3. This is the same info you'll find in /sys, but udev does the work of walking down the hierarchy to collect all the data.

share|improve this answer
Again no luck with my QNAP system, udevadm not available. Nevertheless we do have a comprehensive summary of commands here right now, thanks. – Horst Walter Jun 4 '12 at 8:05

Install gsmartcontrol a GUI tool with loads of information: http://gsmartcontrol.berlios.de/home/images/info_identity.png

gsmartcontrol (1)    - Hard disk drive health inspection tool
share|improve this answer
Useful hint, but the system is a QNAP NAS, I cannot install GUI related tools. Thanks anyway, and sorry that I did not tell this in the question. – Horst Walter Jun 2 '12 at 17:33

I had this problem too. I discovered command:


When run with out args prints usage guide.

To connect disk number to device use like this:

/sbin/get_hd_smartinfo -d 2 -i 1

Press ctrl-c to terminate and it will print "Save file to /tmp/sdX_smart_zzzzzzz" where sdX is your device.

[/var/log] # /sbin/get_hd_smartinfo -d 2 -i 1 
001 Raw_Read_Error_Rate          215244560 119 099 006 OK
242 Lifetime_Reads_To_Host       23449824883497 100 253 000 OK
^CCatch interrupt Singal,Interrupt ..
Save file to /tmp/sdb_smart_563ffc1c
share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.