Jump to content
XPEnology Community

How to get S.M.A.R.T. data for External HDD?


Yuri_S

Recommended Posts

Good day.

Working with DSM 5.2-5967 Update 9.

 

For operational needs use WD Blue 500 Gb HDD, which is connected by USB (using external USB-rack). 

Everything works fine (media streaming and file sharing) except one issue with SMART info and SMART test. Those two button are grey (unavialable) in Control Panel --> External Drive.

 

So my questions is - is it possible to get SMART data for external USB drives?

 

Regards.

smart.jpg

Edited by Yuri_S
Link to comment
Share on other sites

  • Yuri_S changed the title to How to get S.M.A.R.T. data for External HDD?

Hello and welcome to the forum.

 

To answer to your question, It is possible but not from the GUI. You will need to run certain commands from a terminal.

 

In ssh, run this first:

fdisk -l | grep /dev/sd

This will bring up all your disks (internal and external) attached to your box. Your usb device should normally be the one that is named /dev/sdq but please check and most certainly the last one on the list. Now that you know your device you can run several tests and commands.

 

To check if the drive supports SMART:

smartctl -i -d sat /dev/sdq

 

For the short test:

smartctl --test=short -d sat /dev/sdq

 

For the long test:

smartctl --test=long -d sat /dev/sdq

 

For the conveyance test:

smartctl --test=conveyance -d sat /dev/sdq

 

An indication of the time required to run the test will be given to you after you execute the command. You will see something like this:

=== START OF OFFLINE IMMEDIATE AND SELF-TEST SECTION ===
Sending command: "Execute SMART Conveyance self-test routine immediately in off-line mode".
Drive command "Execute SMART Conveyance self-test routine immediately in off-line mode" successful.
Testing has begun.
Please wait 5 minutes for test to complete.
Test will complete after Fri Jul 19 14:08:02 2019

 

To check the results of the tests:

smartctl -l selftest -d sat /dev/sdq

 

To check  the state of SMART on the disk (note the x is in lower case):

 smartctl -x -d sat /dev/sdq

 

To abort any ongoing test (note the X is UPPER CASE)

smartctl -X -d sat /dev/sdq

 

When running a short or long tests you will get this at the end of the output:

Smartctl: Failed to inform synostoraged when testing.

Ignore it. The test will be running anyway.

 

Now you can do a script and add it to your task scheduler so that SMART tests can be  run at desired intervals.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...