fstrim no longer working on some external USB enclosures
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
konsole (Ubuntu) |
Confirmed
|
Undecided
|
Unassigned |
Bug Description
Having upgraded from Jammy to Kinetic I now find that fstrim no longer works on SSD drives in some external USB enclosures.
The issue is caused by the provisioning_mode status for these now being set to disabled, whereas previously they were set to unmap.
Oddly(?) this only occurs on hot-plugging. I have two of these "permanently" plugged in to one system (so there at boot time) and these still show up as unmap.
But if I plug in a third enclosure (same chipset, same SSD model, same SSD firmware version as the second one) it shows up as disabled.
==========
root@benuc:~# lsusb
Bus 002 Device 003: ID 152d:0578 JMicron Technology Corp. / JMicron USA Technology Corp. JMS578 SATA 6Gb/s
Bus 002 Device 002: ID 152d:0578 JMicron Technology Corp. / JMicron USA Technology Corp. JMS578 SATA 6Gb/s
Bus 002 Device 004: ID 152d:0578 JMicron Technology Corp. / JMicron USA Technology Corp. JMS578 SATA 6Gb/s
Bus 002 Device 001: ID 1d6b:0003 Linux Foundation 3.0 root hub
Bus 001 Device 002: ID 8087:0aaa Intel Corp. Bluetooth 9460/9560 Jefferson Peak (JfP)
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
root@benuc:~# cd /sys/
/sys
root@benuc:/sys# find -name provisioning_mode
./devices/
./devices/
./devices/
./devices/
./devices/
root@benuc:/sys# cat ./devices/
unmap
root@benuc:/sys# cat ./devices/
unmap
root@benuc:/sys# cat ./devices/
disabled
==========
(Ignore the ata entries - those are internal drives).
If I reboot the system using the old, kept Jammy kernel (5.15.0-52-generic) the hot-plug shows up as unmap again.
It's the 5.19.0-2?-generic Kinetic kernels which seem to be causing the problem.
I do have a workaround of providing my own udev rule:
ACTION=
which is something I've had to do anyway for some other ASMedia chipsets which do work, but don't get set to unmap by default - 174c:55aa and 174c:235c.
description: | updated |
Status changed to 'Confirmed' because the bug affects multiple users.