On Sun, Dec 22, 2019 at 11:00 AM Josef Bacik <josef@xxxxxxxxxxxxxx> wrote: > > On 12/22/19 12:49 PM, Nikolay Borisov wrote: > > But aren't those only for inline discards e.g. when you have explicitly > > mounted with discard. The use case here is using FITRIM ioctl, does > > Dennis' stuff fix this? > > > > I definitely misread the email, I thought he was talking about the commits being > slow. The async discard stuff won't help with fitrim taking forever, there's > only so much we can do in the face of shitty ssd's. Thanks, My concern isn't this particular built-in Samsung NVMe in an HP laptop, but whether it's sane to enable a weekly fstrim by default in Fedora 32, via util-linux's fstrim.timer. This can't be an uncommon situation, it's commodity name brand hardware. And opensuse and Ubuntu, at least, have enabled this timer by default for years. While the timer is scheduled for Monday at midnight, it's actually likely to run during the first boot on Monday. Is it plausible there's a setup whereby startup is blocked for the duration of this fstrim? If so, that's way more shitty than having a shitty SSD. And if it's not plausible, then does it matter if fstrim takes 5 minutes to run once a week on some SSDs? I'm not seeing blocking, but what about other shitty SSDs? Blast from the past, this is 9 years old now: "At any rate, I definitely think both the online trim and the FITRIM have their uses. One thing that has burnt us in the past is coding too much for the performance of the current crop of ssds when the next crop ends up making our optimizations useless. This is the main reason I think the online trim is going to be better and better. " Chris Mason https://lwn.net/Articles/417809/ Really the industry has been schizo about this issue: totally mixed messaging about the problem, the solution, and providing an interface for it. In one way or another, most SSDs are shitty, depending on your metric. Perhaps we're only just now coming out of the SSD stone age, into the bronze age. But what I don't want to do is make a "one size fits all" weekly timed fstrim cause worse problems. -- Chris Murphy
