udisks icon indicating copy to clipboard operation
udisks copied to clipboard

Fix btrfs lingering mounts

Open RushingAlien opened this issue 8 months ago • 1 comments

Btrfs has an issue where mount can linger after a sudden device disconnect, this is very apparent with USB storage. the psuedo mount option x-systemd.device-bound overrides the default Requires dependency to that of BindsTo which will automatically stop the mount if the device became inactive.

Partly fixes https://github.com/storaged-project/udisks/issues/1359

Please list more filesystems susceptible to lingering mounts in https://github.com/storaged-project/udisks/issues/1359 if you know any so they can be covered as well.

RushingAlien avatar Mar 06 '25 14:03 RushingAlien

https://github.com/systemd/systemd/issues/36634#issuecomment-2704011521

Oh perhaps udisks could use systemd-mount --discover probing? It can probe if the backing device is a removable storage, and applies a BindsTo dependency against said backing dev for the mount unit.

RushingAlien avatar Mar 06 '25 23:03 RushingAlien