Linux Btrfs filesystem development
 help / color / mirror / Atom feed
From: Qu Wenruo <wqu@suse.com>
To: jane <jane@janeirl.dev>, linux-btrfs@vger.kernel.org
Subject: Re: fs forced readonly
Date: Tue, 26 Mar 2024 14:49:01 +1030	[thread overview]
Message-ID: <43137d1c-86d1-44b7-affb-d1080cc1ff56@suse.com> (raw)
In-Reply-To: <bdcc14cf-7e12-4ae7-92c6-a4924158ea64@janeirl.dev>



在 2024/3/26 14:30, jane 写道:
> hello,
> 
> my root mounted btrfs file system becomes forced readonly whenever i try
> to delete a certain directory.
> 
> dmesg output is attached.
> 
> btrfs-check output:
> [1/7] checking root items
> [2/7] checking extents
> data extent[89300512768, 40960] referencer count mismatch (root 257 owner 2995086 offset 258342912) wanted 0 have 1
> data extent[89300512768, 40960] bytenr mimsmatch, extent item bytenr 89300512768 file item bytenr 0
> data extent[89300512768, 40960] referencer count mismatch (root 262401 owner 2995086 offset 258342912) wanted 1 have 0

257 = 0x101
262401 = 0x40101

Another typical memory bitflip from hardware.

Please run memtest to make sure your hardware memory is correct, and 
replace the DIMM if possible.

After all of this, "btrfs check --repair" should be able to repair it.

Thanks,
Qu

> backpointer mismatch on [89300512768 40960]
> ERROR: errors found in extent allocation tree or chunk allocation
> [3/7] checking free space tree
> [4/7] checking fs roots
> [5/7] checking only csums items (without verifying data)
> [6/7] checking root refs
> [7/7] checking quota groups skipped (not enabled on this FS)
> Opening filesystem to check...
> Checking filesystem on /dev/mapper/luks-1d6b7e71-1055-4632-a647-99391f9e4196
> UUID: 8b26e8c1-2566-4991-a0c4-e64da9a46607
> found 121319567360 bytes used, error(s) found
> total csum bytes: 116268816
> total tree bytes: 2147565568
> total fs tree bytes: 1852407808
> total extent tree bytes: 142704640
> btree space waste bytes: 420429213
> file data blocks allocated: 439455162368
>   referenced 173529853952
> 
> btrfs-scrub output:
> UUID:             8b26e8c1-2566-4991-a0c4-e64da9a46607
> Scrub started:    Mon Mar 25 22:59:39 2024
> Status:           running
> Duration:         0:01:50
> Time left:        0:18:58
> ETA:              Mon Mar 25 23:20:31 2024
> Total to scrub:   114.99GiB
> Bytes scrubbed:   10.13GiB  (8.81%)
> Rate:             94.31MiB/s
> Error summary:    no errors found
> 
> $ uname -a
> Linux jane-fedora 6.2.14-300.fc38.x86_64 #1 SMP PREEMPT_DYNAMIC Mon May  1 00:55:28 UTC 2023 x86_64 GNU/Linux
> 
> $ btrfs --version
> btrfs-progs v6.2.2
> 
> $ btrfs fi show
> Label: 'fedora_localhost-live'  uuid: 8b26e8c1-2566-4991-a0c4-e64da9a46607
> 	Total devices 1 FS bytes used 113.02GiB
> 	devid    1 size 149.27GiB used 118.07GiB path /dev/mapper/luks-1d6b7e71-1055-4632-a647-99391f9e4196
> 
> $ btrfs fi df /
> Data, single: total=112.01GiB, used=111.02GiB
> System, DUP: total=32.00MiB, used=16.00KiB
> Metadata, DUP: total=3.00GiB, used=2.00GiB
> GlobalReserve, single: total=368.64MiB, used=0.00B
> 
> please let me know if there's anything i can do to fix this.
> 
> thanks a lot,
> jane

  parent reply	other threads:[~2024-03-26  4:19 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-03-26  4:00 fs forced readonly jane
2024-03-26  4:09 ` jane
2024-03-26  4:19 ` Qu Wenruo [this message]
2024-03-27  3:52   ` jane

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=43137d1c-86d1-44b7-affb-d1080cc1ff56@suse.com \
    --to=wqu@suse.com \
    --cc=jane@janeirl.dev \
    --cc=linux-btrfs@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox