Linux - NewbieThis Linux forum is for members that are new to Linux.
Just starting out and have a question?
If it is not in the man pages or the how-to's this is the place!
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
I had a hard time getting valid values from smartctl on my raspbian. I am using a an external USB 3.0 enclosure on an USB 2.0 port. The raspbian does not allow the UAS driver to load for some reason - instead the dwc_otg driver is used.
Code:
[ 3.091394] usb 1-1.3.4.2: new high-speed USB device number 6 using dwc_otg
[ 3.302288] usb 1-1.3.4.2: New USB device found, idVendor=152d, idProduct=0578
[ 3.307910] usb 1-1.3.4.2: New USB device strings: Mfr=1, Product=2, SerialNumber=3
[ 3.313771] usb 1-1.3.4.2: Product: External Disk 3.0
[ 3.316780] usb 1-1.3.4.2: Manufacturer: JMicron
[ 3.319683] usb 1-1.3.4.2: SerialNumber: 3026E513203588
[ 3.323115] usb 1-1.3.4.2: The driver for the USB controller dwc_otg_hcd does not support scatter-gather which is
[ 3.328911] usb 1-1.3.4.2: required by the UAS driver. Please try an other USB controller if you wish to use UAS.
[ 3.334868] usb 1-1.3.4.2: The driver for the USB controller dwc_otg_hcd does not support scatter-gather which is
[ 3.340918] usb 1-1.3.4.2: required by the UAS driver. Please try an other USB controller if you wish to use UAS.
[ 3.347230] usb-storage 1-1.3.4.2:1.0: USB Mass Storage device detected
[ 3.351004] usb-storage 1-1.3.4.2:1.0: Quirks match for vid 152d pid 0578: 1000000
[ 3.357663] scsi host0: usb-storage 1-1.3.4.2:1.0
[ 4.391968] scsi 0:0:0:0: Direct-Access SAMSUNG SSD PM810 mSATA 0204 PQ: 0 ANSI: 6
[ 4.399403] sd 0:0:0:0: [sda] 125045424 512-byte logical blocks: (64.0 GB/59.6 GiB)
[ 4.406770] sd 0:0:0:0: [sda] Write Protect is off
[ 4.410322] sd 0:0:0:0: [sda] Mode Sense: 47 00 00 08
[ 4.410656] sd 0:0:0:0: [sda] Disabling FUA
[ 4.414157] sd 0:0:0:0: [sda] Write cache: enabled, read cache: enabled, doesn't support DPO or FUA
[ 4.424020] sda: sda1 sda2
[ 4.429071] sd 0:0:0:0: [sda] Attached SCSI disk
But figured out that I can get the values via a "smartctl -d sat ..."
Without the d option the usb bridge type cannot be found automatically.
What I am asking me now is. Does USB 2.0 without UAS support S.M.A.R.T. at all? And how does smartctl can work without UAS?
I am wondering because the wiki article https://de.wikipedia.org/wiki/USB_Attached_SCSI (german) states that UAS introduces SMART capabilities with USB 3.0.
So why does it work at all in my case, as I am not loading the uas driver at all?
See the man page for smartctl, especially for the -d option:-
Quote:
...usbjmicron[,p][,x][,PORT] - this device type is for SATA disks that are behind a JMicron USB to
PATA/SATA bridge. The 48-bit ATA commands (required e.g. for ´-l xerror´, see below) do not work with
all of these bridges and are therefore disabled by default. These commands can be enabled by ´-d usb‐
jmicron,x´. If two disks are connected to a bridge with two ports, an error message is printed if no
PORT is specified. The port can be specified by ´-d usbjmicron[,x],PORT´ where PORT is 0 (master) or 1
(slave). This is not necessary if the device uses a port multiplier to connect multiple disks to one
port. The disks appear under separate /dev/ice names then. CAUTION: Specifying ´,x´ for a device
which does not support it results in I/O errors and may disconnect the drive. The same applies if the
specified PORT does not exist or is not connected to a disk.
Note that Manufacturer: JMicron (in your 1st post) - this presumably refers to the USB?
sat[,auto][,N] - the device type is SCSI to ATA Translation (SAT). This is for ATA disks that have a
SCSI to ATA Translation (SAT) Layer (SATL) between the disk and the operating system. SAT defines two
ATA PASS THROUGH SCSI commands, one 12 bytes long and the other 16 bytes long. The default is the 16
byte variant which can be overridden with either ´-d sat,12´ or ´-d sat,16´.
S.M.A.R.T is designed for HDD (mechanical drives), not SSD.
SSDs have the advantage that they do not require head seeks to another track when the hard drive is re-mapped. It should be noted that many of the S.M.A.R.T. utilities were originally designed for hard disk drives, which means they do not report SSD data correctly. When an attribute value is below the manufacturer’s threshold, the hard disk is considered unreliable. Often the attributes are incorrectly identified and a perfectly healthy SSD is reported as failing.
Therefore it is extremely important to use a utility that specifically supports SSDs.
As there may be some bugs/nonconformity (?) with the USB controller in the enclosure, UAS is not supported. Also there may be lacking support in the dwc_otg driver. https://github.com/raspberrypi/linux/issues/875
@Brains
Hm.. but there are thresholds attributed in the SSD itself. I don´t see anything wrong about using S.M.A.R.T. for SSDs at all. As it still can determine read/write failures, temperatures etc.. What utilities do you have in mind?
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.