2 different NVMe Drives crash, Possible Qubes/Xen bug

Last week write access to my NVMe ssd running Qubes 4.3 was lost with data corruption (on the dom0 root volume) preventing boot. Installing Qubes on another NVMe ssd and proceeding to debug, I determined the data corruption was too pervasive. I successfully made disk images of my various private volumes (no recent backups, oops). After I finished that, my fresh Qubes install on the second NVMe ssd crashed in the same way, still booting but with some data corruption. On subsequent boots it continued to crash in the same way. Switching to plain Debian Trixie on one of the drives resolved the crashing issue so I suspect I’ve run into a regression in Qubes or Xen.

Right now I don’t have access to logs since the systems couldn’t write any information after the drives crashed and there doesn’t appear to be anything leading up to the problem in them. I’ll figure out a way to produce the problem again and preserve logs, could someone point out which ones in particular I should gather?

Hardware:

Originally an Asrock X670E Taichi, tried again with the same result with an Asrock X870E Taichi

AMD 7950X3D CPU

SkHynix P41 1TB SSD, Crucial T710 4TB SSD

Just realized I didn’t define “crash”. I mean the system (dom0, qubes) suddenly lose the ability to write to the disk, the mount ends up R/O with a ton of kernel errors from the filesystem (ext4) not being able to write caches to disk etc. I’ll get log outputs as soon as I can.

Managed to retrieve some logs. Let me know if you need any other data.

[   10.254255] EXT4-fs (nvme0n1p2): mounted filesystem 7a9df742-797c-4415-9d12-69c38fedd286 r/w with ordered data mode. Quota mode: none.
[   10.755462] usbcore: registered new interface driver snd-usb-audio
[   71.369646] device-mapper: thin: 252:2: switching pool to out-of-data-space (error IO) mode
[   71.369680] EXT4-fs warning (device dm-3): ext4_end_bio:368: I/O error 3 writing to inode 262558 starting block 1322080)
[   71.369695] EXT4-fs warning (device dm-3): ext4_end_bio:368: I/O error 3 writing to inode 526627 starting block 1296896)
[   71.369717] EXT4-fs (dm-3): failed to convert unwritten extents to written extents -- potential data loss!  (inode 262558, error -5)
[   71.377792] EXT4-fs warning (device dm-3): ext4_end_bio:368: I/O error 3 writing to inode 526618 starting block 2208768)
[   71.381818] Buffer I/O error on device dm-3, logical block 1320960

dmesg.log (158.7 KB)

xen-serial.log (41.6 KB)

journalctl -m --output=short.log (317.8 KB)

Doesn’t look like a hardware error, just LVM running out of space in the pool hosting the dom0 filesystem. Not unlike this recent post:

Yes, and in my case the only path forward for me was to ditch the LVM filesystem altogether and to reinstall on top of BTRFS instead. I tried installing with the default LVM filesystem option four times, on top of brand-new Samsung SSD’s, and there was no joy each time. Each time I was unable to restore from backup because of this remounting RO problem with some temporary space used during that restore. After having so many issues with installing on the new drives I ran the extended S.M.A.R.T tests on the new drives, and it reported nothing was wrong with them. With BTRFS it runs and restored just fine, and I have seen absolutely no hardware issues since.

This is very strange because this same machine was running just fine for many years on top of LVM/SSD’s but then started having problems with the drives, so I replace them and I just could not get the new SSD’s to cooperate. The older drives had legitimately too many entries in the bad block table so they needed to be replaced, but the drives themselves had not actually failed outright. It was time to replace them anyway, but I can’t help but wondering if some lower level bug didn’t hurry them along to their demise. I don’t know enough about the low level LVM architecture to even guess what might have gone wrong with LVM on the new drives.

This was also possibly related to this same problem.

https://forum.qubes-os.org/t/q-4-3-backup-restore-process-running-out-of-space-but-where-why/42344

Oops, I was coming to the same conclusion thinking about this over night. It might be possible I ran into an actual bug (or hardware fault) on my first SSD, then ran out of space without realizing it while recovering data on the second, smaller SSD. Or perhaps I ran into the same issue on both. Going to have to do some more digging on my end.