Linux 5.1 Hit By A Data Loss Bug Due To Overly Aggressive FSTRIM

Linux FSTRIM/Discard is being too aggressive leading to data loss on certain setups, which at this point seem to be isolated to those using LVM and dm-crypt. The device mapper bug in Linux 5.1 is causing for blocks to be discarded wrongly or too much and that can lead to "massive data loss" issues.
The issue is still being explored by the upstream Linux DM developers but those interested in learning more can do so via this Arch Linux report.
Update; A fix is now available.
46 Comments