To disable USB Attached SCSI (UAS) in GRUB without knowing the specific device ID, append usbcore.autosuspend=-1 and modprobe.blacklist=uas to the GRUB_CMDLINE_LINUX_DEFAULT line in /etc/default/grub. This approach forces the kernel to avoid loading the UAS driver entirely for all USB storage devices, reverting them to the slower but more compatible Bulk-Only Transport protocol. After editing, run sudo update-grub to apply the changes.
Understanding the UAS Compatibility Issue
USB Attached SCSI (UAS) is a protocol designed to improve data transfer speeds over traditional USB mass storage devices by utilizing multiple command queues. While UAS significantly boosts performance on modern hardware, it frequently causes compatibility issues with older external hard drives, cheap USB enclosures, or specific flash controllers. When these devices fail to negotiate the UAS protocol correctly, users often experience system hangs, disconnects during heavy I/O, or complete failure to mount the drive. The standard solution involves preventing the Linux kernel from binding theuas module to these problematic devices. Historically, administrators had to identify the vendor and product IDs of each failing device using commands like lsusb and then add specific usb-storage.quirks to the GRUB configuration. However, this method is tedious because it requires prior knowledge of every connected device's identifier. If you plug in a new drive that also exhibits UAS issues, you must manually edit your configuration again. A blanket disabling strategy is often preferred for stability, especially in server environments or when troubleshooting unpredictable hardware.
Modifying the GRUB Configuration File
The most effective way to disable UAS globally without targeting specific IDs is to blacklist the kernel module at boot time. This ensures that theuas driver is never loaded, forcing the kernel to use the fallback usb-storage driver which implements the Bulk-Only Transport protocol. This method is robust because it does not rely on dynamic device enumeration before the drivers load.
First, open the GRUB default configuration file using a text editor with root privileges. You can use nano or vim depending on your preference:
sudo nano /etc/default/grub
Locate the line that begins with GRUB_CMDLINE_LINUX_DEFAULT. It typically contains quotes around a string of parameters, such as "quiet splash". You need to add two specific parameters inside these quotes. The first parameter tells the kernel to prevent the uas module from loading:
modprobe.blacklist=uas
The second parameter disables USB autosuspend, which can sometimes interfere with USB storage stability even after UAS is disabled:
usbcore.autosuspend=-1
Your final line should look similar to this example:
GRUB_CMDLINE_LINUX_DEFAULT="quiet splash modprobe.blacklist=uas usbcore.autosuspend=-1"
Ensure there are spaces between the existing parameters and the new ones. Do not remove the surrounding quotation marks. Save the file and exit the text editor.
Applying the Changes
Editing the configuration file does not immediately change the boot behavior. You must regenerate the GRUB configuration file to incorporate the new kernel parameters. Run the following command in your terminal:sudo update-grub
On some distributions, particularly those based on systemd-boot or other bootloader variants, the command might be sudo grub-mkconfig -o /boot/grub/grub.cfg, but update-grub is the standard for Debian-based systems and many others. Once this command completes successfully, restart your computer.
Upon reboot, verify that the UAS driver is not loaded by checking the kernel ring buffer or loaded modules:
dmesg | grep uas
If the blacklist was successful, you should see no output indicating that the uas module was probed or bound. Additionally, you can check the loaded modules list:
lsmod | grep uas
An empty result confirms that the module is inactive. Your USB devices will now operate using the Bulk-Only Transport protocol. While this may result in slightly lower throughput compared to UAS, it provides significantly higher reliability for incompatible hardware.
Reverting the Changes
If you determine that your hardware supports UAS properly or you wish to restore maximum performance, you can reverse these steps. Edit/etc/default/grub again and remove modprobe.blacklist=uas and usbcore.autosuspend=-1 from the GRUB_CMDLINE_LINUX_DEFAULT line. Run sudo update-grub and reboot. The system will return to its default USB handling behavior.
For users who occasionally encounter GRUB issues while modifying boot configurations, understanding how to repair the bootloader is essential. See How to Restore GRUB in My Case? for recovery procedures if the system fails to boot after these changes.
Alternative Targeted Solutions
While blacklisting the entire module is the simplest universal fix, it affects all USB storage devices, including high-performance SSDs that benefit from UAS. If you only want to target specific problematic drives without affecting others, you can use device-specific quirks instead. This requires knowing the Vendor ID and Product ID of the failing device. You can find these IDs by runninglsusb and noting the four-digit hexadecimal codes separated by a colon. Then, add a quirk to your GRUB command line:
usb-storage.quirks=VID:PID:u
The :u flag tells the kernel to treat the specified device as a UAS-capable device, but if that fails, it falls back. Alternatively, using :b forces bulk-only transport for that specific ID. This method is more granular but requires manual maintenance whenever new devices are added. For complex scenarios involving ISO booting or partition layouts, refer to Linux Boots Grub - How to Fix a Broken grub.cfg to ensure your configuration syntax remains valid.
Frequently Asked Questions
Does disabling UAS reduce USB speed significantly?
Yes, UAS can offer up to 20-30% better throughput than Bulk-Only Transport due to command queuing. However, for mechanical hard drives or low-quality USB enclosures, the overhead of negotiating UAS often causes latency spikes that make Bulk-Only Transport feel smoother. The speed difference is usually negligible for general file copying tasks.
Can I disable UAS for only one specific USB port?
No, the modprobe.blacklist parameter applies to the kernel module globally, not to individual ports. To target a specific physical port, you would need to use USB hub quirks or switch the device to a different controller, but software-level port isolation is not supported in standard GRUB configurations.
Why did my USB drive disappear after adding the blacklist parameter?
This is unlikely if the configuration is correct. If it happens, check the dmesg logs for errors related to usb-storage. It is possible that the device requires UAS to function at all, though rare. In such cases, removing the blacklist parameter and using specific quirks is the better approach.
Is module_blacklist deprecated in newer kernels?
The modprobe.blacklist mechanism is still active and supported in recent Linux kernels. While some developers prefer using initramfs hooks or udev rules for dynamic management, the GRUB kernel parameter remains a reliable and simple method for static configuration across most distributions.
How do I check if UAS is currently enabled for my device?
You can check the driver bound to your USB device by looking at the sysfs entry. Navigate to /sys/bus/usb/devices/ and find your device directory. Check the driver symlink; if it points to usb-storage, UAS is disabled. If it points to uas, the fast protocol is active.