S.M.A.R.T. on USB drives

File systems- EXT3, EXT4, XFS & JFS, partitioning and mount points

S.M.A.R.T. on USB drives

Postby kochin » Wed 17. Oct 2012, 21:33

Not all USB hard drives support S.M.A.R.T. One of the USB hard drives supports it is WD My Book Studio II. Unfortunately OMV 0.4.1 and earlier aren't able to read S.M.A.R.T. information from it. The failure is the result of smartd and smartctl unable to automatically determine how to communicate with that hard drive. They require a '-d xxx' option to tell them the correct device type.

In order to use S.M.A.R.T. support on WD My Book Studio II, I need to specify '-d sat' option. However, OMV apparently doesn't have any place to let me specify that option for my hard drive. After a little study on the source code, I created this patch (see the attachment) which adds a feature to let you specify S.M.A.R.T. device type option and apply that option to smartd and smartctl.

To use the patch, you need to have OMV 0.4.1 installed. Download and unzip the attachment to your OMV device. Run this command at root directory to check:
Code: Select all
# patch --dry-run -p1 < smartdevtype.patch
If all seem fine, run this command at root directory to apply: (Use it at your own risk.)
Code: Select all
# patch -p1 < smartdevtype.patch

Refresh your OMV web interface, and then go to Storage/Physical Disks. Select the hard drive you want and edit its properties. Enter the S.M.A.R.T. device type for your hard drive.
Specifying S.M.A.R.T. device type option
hdparm.jpg (61.17 KiB) Viewed 1132 times

Then go to Storage/S.M.A.R.T./Devices, and select your hard drive. Click either Detail or Information button to see whether S.M.A.R.T. information can be retrieved successfully.
Retrieving S.M.A.R.T. information
smart.jpg (76.88 KiB) Viewed 1132 times

But, how do you know what device type to use'? Most USB hard drives probably need either 'scsi' or 'sat' option. There are other device types you can try with smartctl command. Please read http://linux.die.net/man/8/smartctl for details.
S.M.A.R.T. device type patch to omv 0.4.1
(1.97 KiB) Downloaded 70 times
  • OpenMediaVault 0.5.53 (Sardaukar)
  • PLUGINS: nut, omvextrasorg, minidlna, transmissionbt, eXtplorer, dnsmasq
  • HARDWARE: Pogoplug Classic (POGO-E02) + SanDisk Cruzer Blade 4GB + WD3200BEVT 320GB
  • PROCESSOR: Feroceon 88FR131 rev 1 (v5l) 1.2GHz
  • SYSTEM: Debian Wheezy (2.6.32-5-kirkwood armv5tel)
Posts: 27
Joined: Fri 28. Sep 2012, 18:03

Return to General Storage Info

Who is online

Users browsing this forum: No registered users and 2 guests