linux-btrfs.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Qu Wenruo <quwenruo.btrfs@gmx.com>
To: "Swâmi Petaramesh" <swami@petaramesh.org>,
	"'linux-btrfs@vger.kernel.org'" <linux-btrfs@vger.kernel.org>
Subject: Re: Kernel 5.4 - BTRFS FS shows full with about 600 GB Free ?
Date: Sun, 22 Dec 2019 17:37:47 +0800	[thread overview]
Message-ID: <a39bd758-69d2-cf16-de39-36e22cefe233@gmx.com> (raw)
In-Reply-To: <bd183df9-4742-301d-251c-443d99d170c7@petaramesh.org>



On 2019/12/22 下午5:00, Swâmi Petaramesh wrote:
> Hi again,
>
> Le 22/12/2019 à 09:12, Qu Wenruo a écrit :
>> So if you have enough uncommitted metadata, that check will be triggered
>> and suddenly returns 0 available space, even 1 sec early you still get
>> tons of available space.
>
> With « uncommitted metadata » do you mean that this situation is only
> temporary and should end once all transactions are commited to disk ?

Yes. The temporary part also matches with one kind reporter's description.
So for that v5.4 temporary 0 available, it should be the case.

>
> Because in the one disk on which I observe this (and which passes a full
> btrfs check with bells and whistles) it still shows 0% free after 2 days
> and several unmounts / remounts...
>
> Furthermore I've conected it to machines using 5.3 and even 4.15
> kernels, and they *ALL* state that the free disk space is zero - even
> though I can understand if « That check is from 2015 ».

Then for older kernels, I'm afraid you're seeing a different problem.
If you feel like to try to start hacking the kernel, I could provide
some snippet to add debug output and pin down the problem.



But there is one valid behavior which may cause such 0 available space
situation.
Are you using RAID1 or RAID10 with hugely unbalanced disk size?
If so, there could be a case that btrfs can't find two devices with
enough un-allocated space to fulfill a chunk allocation.

E.g. 1T + 1T + 10T disks RAID1. You can only utilize 2T space (1T from
each smaller devices, and 2T from that larger device).
The remaining 8T from that larger device can't be utilized for RAID1.

In that case, you will still have unallocated space, but any profile
requiring two disks is unable to use it.

>
> That still seems to boild down to : Once I got this error it seems I
> cannot step out of it using any reasonably recent kernel.
>
> So I may have either to patch my kernel or wait for the patch to reach
> #Arch kernels... and hope it actually fixes it.
>
> (I have to admit that I haven't yet fully understood the technical
> aspects of this overcommit story...)
>
> I'm also worried that on my machines that does NOT show this problem on
> their own main filesystems, this could happen anytime soon ?

We need extra info to further determine the cause of the persistent 0
available space problem.
`btrfs fi usage` output would help a lot.

But still, that 2015 check can still cause 0 available space, if your
metadata available space is pretty low.

Thanks,
Qu

>
> Thanks anyway very much for your help.
>
> Kind regards.
>
> ॐ
>

  parent reply	other threads:[~2019-12-22  9:39 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-12-21 10:59 Kernel 5.4 - BTRFS FS shows full with about 600 GB Free ? Swâmi Petaramesh
2019-12-21 12:00 ` Qu Wenruo
2019-12-21 12:07   ` Swâmi Petaramesh
2019-12-21 12:16     ` Qu Wenruo
     [not found]       ` <cbbfe8a4-ff7b-4bea-313c-e1acbf9ee61a@petaramesh.org>
2019-12-21 12:53         ` Qu Wenruo
2019-12-21 12:19   ` Swâmi Petaramesh
2019-12-22  7:55   ` Swâmi Petaramesh
2019-12-22  8:12     ` Qu Wenruo
2019-12-22  9:00       ` Swâmi Petaramesh
2019-12-22  9:22         ` Swâmi Petaramesh
2019-12-22  9:37         ` Qu Wenruo [this message]
2019-12-22 10:15           ` Swâmi Petaramesh

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=a39bd758-69d2-cf16-de39-36e22cefe233@gmx.com \
    --to=quwenruo.btrfs@gmx.com \
    --cc=linux-btrfs@vger.kernel.org \
    --cc=swami@petaramesh.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;
as well as URLs for NNTP newsgroup(s).