Hi All. I’m having an issue that I am hoping I can get some help with.

I have been using linux on this particular laptop for over a year now, and for the past 6 or so months (right around the time I upgraded to Plasma 6, but I think it is just a coincidence) about 50% of the time, when I update all my packages via package manager, the whole system freezes. Like, hard freezes. Waiting any amount of time won’t get me out of it. I have to hold the power button to power it down. I can’t use ctrl+alt+F3 or whatever to get another TTY. Mouse doesn’t move. Nothing works.

It originally happened with OpenSUSE Tumbleweed on btrfs. I thought maybe it was btrfs, so I reinstalled with ext4. Same issue. I tried Manjaro. Same issue. I tried EndeavourOS (wasn’t really expecting different behavior at this point). Same issue.

Now I am thinking, what could cause an issue like this? Well, a package manager update just is a ton of file I/O operations, right? Could I have bad RAM and that is getting written to disk? Well, I did a memtest today and it came back perfect. So now I’m thinking it might be the SSD, but I’m not even sure how to check that.

Does anyone have any ideas of what might be going on or what I should do to fix it or debug it?

  • DandroidOP
    link
    11 month ago

    Thank you for the suggestion. I am unfamiliar with this, but I am reading about it now.

    • @[email protected]
      link
      fedilink
      English
      3
      edit-2
      1 month ago

      For what it’s worth, I’ve never had to change my io scheduler in the nearly twenty years I’ve used Linux. You can check your current scheduler with the following command: cat /sys/block/sda/queue/scheduler (change the block device to whatever yours is…sda, nvme0n1, etc.).

      In my case, it was already bfq: one mq-deadline kyber [bfq]

    • @[email protected]
      link
      fedilink
      English
      2
      edit-2
      1 month ago

      Even with nvme drives which supposedly “don’t need” to use BFQ, I STILL always swap it since it maintains responsiveness across the system during heavy IO loads. I used to have similar full system freezes when downloading steam games which notoriously overload your IO in Linux. BFQ was the solution every single time.

      Edit Try following the instructions detailed in this post to add a systemd rule to set the scheduler: https://stackoverflow.com/questions/1009577/selecting-a-linux-i-o-scheduler

      The second answer that shows an actual rules.d file example has always worked for me. If using nvme or old school spinning rust you’ll need to change it up a bit. Instead of “noop” set it to “BFQ”.