* Re: btrfs corruption across different storage configurations. Both with free addressable free storage
[not found] ` <CAC=1GgHNn17ygWL0tF26LGm+=5M4KrKoeMpq9YE794EothX++w@mail.gmail.com>
@ 2026-11-25 20:41 ` Marcus Lell
0 siblings, 0 replies; only message in thread
From: Marcus Lell @ 2026-11-25 20:41 UTC (permalink / raw)
To: Przemek Klosowski; +Cc: linux-btrfs, linux-kernel
Hi, Przemek,
23 Nov 2026 21:45:10 Przemek Klosowski <przemek.klosowski@gmail.com>:
> hi,
> I am not a btrfs developer but I track the dev list. I had a corrupted fs in the past, and it really was due to hardware problem on my system---memory errors due to controller parameters drifting over time. I ran memtest86+, saw the errors, then ran the BIOS memory test, also finding errors, which caused BIOS to recompute the settings. Since then I ran memtest occasionally, see no errors, and have no problem with the FS.
Thank for your reply.
I will check that, and report back. But since I'm using 6.18.x, I see no problems at all. I think the bug? was introduced in 7.1.x, so it is worth to find out. Maybe others are seeing something similar. The least thing, I'd like to see, Linux to become unstable.
> I don't know if this is relevant to you, but please run memtest (best the bootable version, but if you can't at least boot in mimimal linux and run memtester on as much memory as you can from the shell prompt).
> Hope this is helpful
> p
>
> On Mon, Nov 23, 2026 at 4:48 AM Marcus Lell <marcus.lell@gmail.com> wrote:
>> [please CC me, as I'm off list]
>>
>> I know it's a late report, but I thought, you may know about this one...
>>
>> I experienced severe Btrfs corruption twice, on Linux 7.1.10 and 7.1.12, using substantially different storage configurations.
>>
>> Incident 1 — Linux 7.1.10
>>
>> I was running Btrfs on LUKS/dm-crypt over md RAID5, using four SATA devices with 64 KiB chunks. The incident occurred during or after a RAID5 reshape and enlargement of the encrypted device. After enlarging the crypt layer, I tried mounting the filesystem, but "mount.btrfs" failed.
>>
>> Subsequent diagnostics revealed metadata errors at offsets beyond Btrfs's reported size:
>>
>> "total_bytes = 20001389936640"
>>
>> - Wanted bytenr "20015028908032", found "8567551700635656859"; checksum wanted "0x836ea028", found "0x8db80d65".
>> - Wanted bytenr "20024023199744", found "12778909791338521120"; checksum wanted "0xfd168e20", found "0x95744024".
>>
>> These offsets were approximately 13.65 GB and 22.64 GB beyond the reported filesystem size, but within the underlying device's addressable capacity.
>>
>> I did not touch the underlying filesystem during the enlargement. Just at the end. I was surprised, that an untouched filesystem could go so messed up. I thought, it could be an mdadm grow failure.
>>
>> I made extensive attempts to diagnose and recover the filesystem. I tried superblock recovery, "btrfs check --repair", "btrfs restore", "btrfs-find-root", mounting with recovery options, and "dmsetup"-based approaches. I also used a device-mapper snapshot to rule out concurrent changes during checking. Despite these efforts, I could not restore a usable filesystem. "btrfs restore" recovered some files but reported checksum errors.
>>
>> Incident 2 — Linux 7.1.12
>>
>> I was running Btrfs on an approximately 1 TB root logical volume on LVM, on a single 2 TB NVMe device, without md RAID. The root filesystem became unusable. I recall seeing what appeared to be the same kind of "bytenr" failure, although I no longer have the logs to confirm the exact error. I had not observed unusually large writes before the failure.
>>
>> I lost the logs of the first attempt, that I saved on the root partition. I was like to be afraid to cope with the responses of you. (I'm shy)
>>
>> Because the second incident occurred on a substantially different storage configuration, I find it less likely that the problem was specific to the RAID reshape or crypt-layer resizing in the first incident.
>>
>> I want you to help make the btrfs filesystem more error prone. But I can only point into the direction. I cannot prove that such a write occurred or that both incidents shared the same root cause, but I believe the recurrence and the first incident's specific offsets warrant investigation.
>>
>> I don't know, how to help further, but I don't dare to trust Linux 7.1.x and successors, with 7.0.x I believe, this is the last stable one. I need to upgrade sooner or later, so please find the root cause of this behavior...
>>
>> Marcus Lell
--
Return to the point of no return._
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2026-11-25 20:41 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
[not found] <b8b122c5-87c7-4363-b3cc-c91d24ff4d2d@gmail.com>
[not found] ` <CAC=1GgHNn17ygWL0tF26LGm+=5M4KrKoeMpq9YE794EothX++w@mail.gmail.com>
2026-11-25 20:41 ` btrfs corruption across different storage configurations. Both with free addressable free storage Marcus Lell
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®