How to enable SMART?
I want to conduct a SMART test on my drive but it was disabled. So, i used
sudo smartctl -s on /dev/sda
but the result was
smartctl 5.41 2011-06-09 r3365 [i686-linux-3.2.0-26-generic] (local build)
Copyright (C) 2002-11 by Bruce Allen, http://smartmontools.sourceforge.net
=== START OF ENABLE/DISABLE COMMANDS SECTION ===
Error SMART Enable failed: scsi error aborted command
Smartctl: SMART Enable Failed.
A mandatory SMART command failed: exiting. To continue, add one or more '-T permissive' options.
How to overcome this problem?
Check inside your BIOS if the SMART functionality is enable. Depending on your hardware it's on different menus but generally you can find it where your hard drives are defined or in advanced features.
If this is not enough you can afterwards enable it with hdparm.
Check if you can use it with :
sudo hdparm -I /dev/sda
/dev/sda being the hard drive you want to check
this command will show you what's enabled or not
To enable SMART if not enabled you can do this command :
sudo smartctl --smart=on /dev/sda
When you ends with error it may means two things :
- You simply can't do it
- you need to specify the BUS used
For the second part you must give use more details (the hdparm -I output for instance, the hard drive model, the computer or motherboard model, etc etc)
The easiest and 100% sure working method is by changing the value inside the BIOS.
Best regards.
For whom the answer by Antoine Rodriguez does not work (like in my case, because I couldn't access my external HDD in my BIOS), you might want to check out this anwer: https://unix.stackexchange.com/a/109736/197569
It states that you can specify a device type when running Smartmontools as follows:
-d TYPE, --device=TYPE
Specify device type to one of: ata, scsi, sat[,N][+TYPE],
usbcypress[,X], usbjmicron[,x][,N], usbsunplus, marvell,
areca,N, 3ware,N, hpt,L/M/N, megaraid,N, cciss,N, auto, test
You can find your device type with the same software by entering:
smartctl --scan