failed to repair damaged filesystem, aborting | kernel BUG at fs/btrfs/extent-tree.c:4955!
Hello, btrfs failed me big time today. I am using archlinux, linux 5.16. My laptop started strangely lagging. I discovered, all of the sudden, btrfs was mounted ro. I rebooted and then the system acted very weird. I have discovered it was because ANY write operation just hangs indefinitely. For example 'touch test' just hangs. removing snapshot hangs. I should probably mention btrfs is inside of luks. I have cloned the disk and booted ubuntu live from USB and started poking around the clone.
I uploaded dmesg and whole result of btrfs check here: https://up.jvi.cz/0X.txt
The SSD drive itself is okay according to SMART. I cloned it no problem.
The filesystem is in a state, that even check --repair can not help it:
backpointer mismatch on [3229016064 28672]
attempting to repair backref discrepancy for bytenr 3229016064
extent start and backref starts don't match, please use btrfs-image on this file system and send it to a btrfs developer so they can make fsck fix this particular case. bytenr is 3229016064, bytes is 28672 failed to repair damaged filesystem, aborting
Scrub hangs too:
root@ubuntu:/mnt/jvb# btrfs scrub status . UUID: e22cc9ec-1607-413b-91a4-f09a9c03fbeb Scrub started: Fri Feb 4 13:28:11 2022 Status: running Duration: 0:14:01 Time left: 0:00:00 ETA: Fri Feb 4 13:42:16 2022 Total to scrub: 394.37GiB Bytes scrubbed: 0.00B (0.00%) Rate: 0.00B/s Error summary: no errors found
Is there something I can do to fix it? Whom to send the image with metadata? It has 3+ GB.
Or should I start reinstalling and recovering from backup?
Josef
Quoted 10 lines · Josef Vybíhal
Hello, btrfs failed me big time today. I am using archlinux, linux 5.16. My laptop started strangely lagging. I discovered, all of the sudden, btrfs was mounted ro. I rebooted and then the system acted very weird. I have discovered it was because ANY write operation just hangs indefinitely. For example 'touch test' just hangs. removing snapshot hangs. I should probably mention btrfs is inside of luks.
I have cloned the disk and booted ubuntu live from USB and started poking around the clone.
Quoted 2 lines
I uploaded dmesg and whole result of btrfs check here:
https://up.jvi.cz/0X.txt
Attached dmesg is 5.13 kernel. Are you using autodefrag mount option with this file system? If so, I suggest disabling it with 5.16 series until some bugs get fixed up.
Quoted 2 lines
Is there something I can do to fix it? Whom to send the image with metadata? It has 3+ GB.
I'd say if you can reproduce with current stable or mainline kernel, it's worth going to the trouble. Most of the development work is predicated on the most recent kernels, either the problem is already fixed in a newer kernel, or if it's still a bug then it needs to be fixed in a current kernel before it would get backported. While you can run into new bugs (like autodefrag issues in 5.16 series), most everyone on the list and in #btrfs will know about the current issues, whereas older issues in older kernels, it's a coin toss if someone remembers or has time to look it up.
Quoted 2 lines
Or should I start reinstalling and recovering from backup?
That's surely the fastest option.
Signature · 1 line
Chris Murphy