I created a simple PoC udev rule to mount USB Storage devices with the "sync 
option.
Available here : 
https://github.com/larina3315/personal-stuff/blob/main/linux/10-usb-storage.rules

Currently, USB Storage devices are mounted without the "sync" option, causing 
their writes to be cached.
This causes an issue, especially with GUI file managers like GNOME Files, where 
after a file copy operation, it would notify the user that the operation has 
been completed. If the user then tries to unmount the USB Storage device, they 
get notified that data is still being written to disk and that they should not 
remove the USB Storage device from their PC/Laptop/device.

This can take a more severe form if the user is using a CLI/GUI utility that 
DOES NOT inform the user that data is still being written, like the 'cp' CLI 
utility, the user might be misled into thinking that all writes have finished 
and plug the USB drive out, at which point data corruption due to unfinished 
writes occur.

This is why, I think functionality should be included in Fedora Linux (or 
atleast in Fedora Workstation and other desktop spins) such that USB Storage 
devices are mounted with the "sync" options by default.
--
_______________________________________________
devel mailing list -- devel@lists.fedoraproject.org
To unsubscribe send an email to devel-le...@lists.fedoraproject.org
Fedora Code of Conduct: 
https://docs.fedoraproject.org/en-US/project/code-of-conduct/
List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines
List Archives: 
https://lists.fedoraproject.org/archives/list/devel@lists.fedoraproject.org
Do not reply to spam, report it: 
https://pagure.io/fedora-infrastructure/new_issue

Reply via email to