Hi Andre,

Great research! Lets have a look at that patch you found.

ubuntu-noble$ git log --grep "btrfs: protect folio::private when attaching 
extent buffer folios" origin/master-next
commit 78f0e5fd1fce33785a3454f5712a6f6160201bd5
Author: Qu Wenruo <w...@suse.com>
Date:   Thu Jun 6 11:01:51 2024 +0930
Subject: btrfs: protect folio::private when attaching extent buffer folios
    
$ git describe --contains 78f0e5fd1fce33785a3454f5712a6f6160201bd5
Ubuntu-6.8.0-44.44~547

This is a part of 6.8.0-44-generic, which is currently in -proposed. It should 
be
released this week as part of SRU cycle 2024.08.05.

If you need it right now, you can enable -proposed and install 6.8.0-44-generic,
but I think it should be out in a few days.

Thanks,
Matthew

** Also affects: linux (Ubuntu)
   Importance: Undecided
       Status: New

** No longer affects: linux-meta (Ubuntu)

** Also affects: linux (Ubuntu Noble)
   Importance: Undecided
       Status: New

** Changed in: linux (Ubuntu)
       Status: New => Fix Released

** Changed in: linux (Ubuntu Noble)
       Status: New => Fix Committed

-- 
You received this bug notification because you are a member of Kernel
Packages, which is subscribed to linux in Ubuntu.
https://bugs.launchpad.net/bugs/2080039

Title:
  Kernel BUG: Bad page state in process kswapd0

Status in linux package in Ubuntu:
  Fix Released
Status in linux source package in Noble:
  Fix Committed

Bug description:
  Since installing 24.04 two months ago, I've experienced a few random
  full-system freezes that required a hard-reset to recover. Up until
  now, I was not able to find the cause - plugging in a monitor to the
  system would just display nothing, and the journal logs would just
  stop abruptly.

  My first instinct was bad memory, so after it happened last week I ran
  memtest for several hours, but it did not find any memory errors.

  However I now believe I have found the actual cause, because it just
  happened again and luckily this time the journal saved the start of a
  kernel BUG message:

  BUG: Bad page state in process kswapd0  pfn:3f053e
  page:000000000f35bcf8 refcount:0 mapcount:0 mapping:000000000e24c844 
index:0x2bcbd pfn:0x3f053e
  aops:btree_aops [btrfs] ino:1
  flags: 0x17ffffc0000008(uptodate|node=0|zone=2|lastcpupid=0x1fffff)
  page_type: 0xffffffff()

  After some digging, I found this kernel bug report:
  
https://lore.kernel.org/lkml/CABXGCsPktcHQOvKTbPaTwegMExije=Gpgci5NW=hqoro-s7...@mail.gmail.com/

  that appears to describe the exact same bug (I am also using btrfs as
  the root partition, and my swap file is also on that btrfs
  filesystem).

  Then I also found this kernel patch:
  
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?id=f3a5367c679d31473d3fbb391675055b4792c309

  that appears to be a fix for the above bug.

  To try to check if this fix is present in my kernel (no idea if this
  is valid), I installed the linux-source package, extracted the archive
  in /usr/src/linux-source-6.8.0, and checked the file modified by the
  patch mentioned above - and the changes do not appear to have been
  made.

  So if the patch has not been applied, could this please be done? If it
  has actually been applied, then this is some other bug and I need to
  do more investigation...

  For the time being I have disabled swap to hopefully try and avoid the
  crash.

  # uname -a
  Linux server 6.8.0-41-generic #41-Ubuntu SMP PREEMPT_DYNAMIC Fri Aug  2 
20:41:06 UTC 2024 x86_64 x86_64 x86_64 GNU/Linux

  # cat /proc/version_signature
  Ubuntu 6.8.0-41.41-generic 6.8.12

  # lsb_release -rd
  No LSB modules are available.
  Description:    Ubuntu 24.04.1 LTS
  Release:        24.04

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/linux/+bug/2080039/+subscriptions


-- 
Mailing list: https://launchpad.net/~kernel-packages
Post to     : kernel-packages@lists.launchpad.net
Unsubscribe : https://launchpad.net/~kernel-packages
More help   : https://help.launchpad.net/ListHelp

Reply via email to