Connection problem with USB3 external storage on Linux (UAS driver problem)
I had this same issue on Mint 18, but the solution I found can probably be applied to *Ubuntu 15/16 as well as similar Linux distributions. For me, however, I was getting an irrecoverable system lockup soon after seeing the UAS errors in dmesg.
My enclosure has an ASMedia ASM1053 chip, which seems to have issues with the UAS module of my kernel (4.4.0-72-generic).
After a bit of searching, I combined two solutions I found: this one, which YtvwlD mentioned and this one.
First, you must get the hardware ID of your device using the lsusb command. Once you do that, locate your external/enclosure/bridge. It might show up like below:
Bus 002 Device 002: ID 174c:5136 ASMedia Technology Inc. ASM1053 SATA 6Gb/s bridge
In my case, the ID is 174c:5136.
After that, you must create a file in /etc/modprobe.d/ so the proper device is blacklisted from using UAS (which is causing issues), update the initramfs image using update-initramfs, then reboot for the change to take effect.
$ echo options usb-storage quirks=174c:5136:u | sudo tee /etc/modprobe.d/blacklist_uas.conf
$ sudo update-initramfs -u
$ sudo reboot
Of course, replace "174c:5136" with the hardware ID of your bridge/enclosure/external. If done correctly, you should see a message like this from dmesg when you connect your device after rebooting:
[ 93.985002] usb 4-1: UAS is blacklisted for this device, using usb-storage instead
I haven't had any issues with my enclosure since.
I ran into this issue today on a 4.8.0 kernel.
According to this forum post it can be circumvented by
$ echo options usb-storage quirks=357d:7788:u | sudo tee /etc/modprobe.d/blacklist_uas_357d.conf
$ sudo update-initramfs -u
and rebooting.
In order to apply the quirk mentioned by other answers on the fly, you can also set it at runtime:
echo "152d:0583:u" | sudo tee /sys/module/usb_storage/parameters/quirks
Replace 152d:0583
with the USB device ID of your device, of course.
This will set the quirks
parameter of the usb-storage
module to the aforementioned value without requiring a reboot.