Closed jpf91 closed 1 week ago
I see this error, too. First time happened yesterday as reported in https://github.com/koverstreet/bcachefs/issues/716#issuecomment-2243914563. I did an fsck,fix_errors
and it was working fine until now when it recurred, see log below.
Versions
I just did another fsck
but interestingly it didn't find anything. So I guess the errors it found in #716 were related to the other error.
I'm trying to fix the assertion pop, but I don't see an assert at line 524 in either 6.9 or 6.10; can you show me what you have there?
Thank you for looking into this!
It's actually an 6.8 kernel, but based on the ubuntu kernel sources. I verified my journal logs again and double-checked that this error was indeed seen with the 6.8.8-2-pve
kernel. It took some time to find the proper sources, but this kernel is based on Ubuntu-6.8.0-38.38
which can be found here: https://git.proxmox.com/?p=mirror_ubuntu-kernels.git;a=commit;h=ffe6f6578643a9ae802c3eb5a64096f51a0e0524 (Proxmox adds some more patches, but nothing bcachefs related)
Direct link to the source code with the assert: https://git.proxmox.com/?p=mirror_ubuntu-kernels.git;a=blob;f=fs/bcachefs/io_write.c;h=2c098ac017b30b6a4b5d016e9f5dde93ee258f2f;hb=ffe6f6578643a9ae802c3eb5a64096f51a0e0524#l524
And here's an excerpt:
503 static void __bch2_write_index(struct bch_write_op *op)
504 {
505 struct bch_fs *c = op->c;
506 struct keylist *keys = &op->insert_keys;
507 unsigned dev;
508 int ret = 0;
509
510 if (unlikely(op->flags & BCH_WRITE_IO_ERROR)) {
511 ret = bch2_write_drop_io_error_ptrs(op);
512 if (ret)
513 goto err;
514 }
515
516 if (!bch2_keylist_empty(keys)) {
517 u64 sectors_start = keylist_sectors(keys);
518
519 ret = !(op->flags & BCH_WRITE_MOVE)
520 ? bch2_write_index_default(op)
521 : bch2_data_update_index_update(op);
522
523 BUG_ON(bch2_err_matches(ret, BCH_ERR_transaction_restart));
524 BUG_ON(keylist_sectors(keys) && !ret);
Upstream 6.8.8 has the same assert here: https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/tree/fs/bcachefs/io_write.c?h=v6.8.8#n524
Fixed by d26935690c03 bcachefs: Fix bch2_extents_match() false positive
Hi there,
I'm currently testing bcachefs mostly for its caching features combined with flexible storage layouts (i.e. using disks with different sizes). For this use case, it already seems to work better than btrfs and zfs 😀
My basic setup is like this:
This worked fine for some basic containers. However, when configuring a Jellyfin container it caused an emergency read-only when starting the initial media library scan. The filesystem did also not want to unmount, but after a reboot it mounted cleanly again and in general works just fine. I didn't dare to test whether the issue is reproducible though :see_no_evil: Below are dmesg logs, kernel version and filesystem setup:
FS setup
dmesg log
(BTW, am I leaking any important key data here? If so please let me know :wink: )
I also sometimes see these, but I think they are unrelated:
OS Version etc
I realize this is a bit old as bcachefs is rapidly changing. I'm also seeing some more bugs (tvheadend TV recording files being cut off, QEMU raw disk images placed on bcachefs not mounting inside linux VMs (disk timeouts)). But I think I'll only report those if I can reproduce with a newer kernel. Once the ubuntu mainline PPA has the 6.10 kernel release ready for amd64, I'll see if I can reproduce the issue there.