Linux Btrfs filesystem development
 help / color / mirror / Atom feed
From: Hugo Mills <hugo@carfax.org.uk>
To: linux-btrfs.tebulin@xoxy.net
Cc: linux-btrfs@vger.kernel.org
Subject: Re: Kernel 3.19 and still "disk full" even though 'btrfs fi df" reports enough room left?
Date: Wed, 18 Nov 2015 19:08:57 +0000	[thread overview]
Message-ID: <20151118190857.GY24333@carfax.org.uk> (raw)
In-Reply-To: <564CC90F.3060703@gmail.com>

[-- Attachment #1: Type: text/plain, Size: 2613 bytes --]

On Wed, Nov 18, 2015 at 07:53:03PM +0100, linux-btrfs.tebulin@xoxy.net wrote:
> Hello there!
> 
> I'm stumbling over this regularly. I explicitly upgraded the kernel to
> avoid this, but it still occurs me every few months:
> 
>   $ touch foo
>   touch: »foo“ kann nicht berührt werden: Auf dem Gerät ist kein
> Speicherplatz mehr verfügbar
>   $ sudo btrfs fi df /
>   Data, single: total=101.14GiB, used=78.99GiB
>   System, DUP: total=32.00MiB, used=16.00KiB
>   Metadata, DUP: total=9.00GiB, used=8.48GiB
>   unknown, single: total=512.00MiB, used=832.00KiB
> 
> Whut? Why? WTF?

   Running out of metadata space, probably, although it's impossible
to tell from only this information -- see below.

>   $ uname -a
>   Linux neptun 3.19.0-31-generic #36~14.04.1-Ubuntu SMP Thu Oct 8
> 10:21:08 UTC 2015 x86_64 x86_64 x86_64 GNU/Linux
> 
> dmesg is empty. Resolution is to delete a whole bunch of btrfs
> subvolumes which are produced by apt-btrfs-snapshot. I run a
>    sudo btrfs balance start -dusage=5 /
> afterwards as part of my regular "i have no clue what the heck is wrong
> with this; maybe it will help & mend my problem" process.
> 
> This is annoying. Why is even btrfs own "disk free" utility lying to me?

   I't snot lying to you -- you're just not seeing the whole
story. You can't tell everything about disk usage from btrfs fi df.
You need to use btrfs fi show as well to get the full information (or
btrfs fi usage, which combines the output of both). See the FAQ[1] for
how to interpret the output.

> How to fix this? How to avoid this? How to get notified about this?

   Without seeing your btrfs fi show output, I can't say for sure, but
the usual problem in this instance is that you've got all your
available space allocated to either data or metadata, and the FS needs
more metadata space and can't allocate it. The solution is to free up
some of the data allocation, using a filtered balance. See the FAQ[2]
for how to spot the problem, and what to do about it.

[1] https://btrfs.wiki.kernel.org/index.php/FAQ#Understanding_free_space.2C_using_the_original_tools
[2] https://btrfs.wiki.kernel.org/index.php/FAQ#if_your_device_is_large_.28.3E16GiB.29

   Hugo.

> - Ben
> 
> P.S.: Just as user feedback: For /srv I'm using on the very same system
> ZFS since the very first day. With snapshots & all the fancy stuff like
> ZRAID-1, lz4, ... My number of Issues there: 0
> 

-- 
Hugo Mills             | Close enough for government work.
hugo@... carfax.org.uk |
http://carfax.org.uk/  |
PGP: E2AB1DE4          |

[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 836 bytes --]

  reply	other threads:[~2015-11-18 19:08 UTC|newest]

Thread overview: 24+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-11-18 18:53 Kernel 3.19 and still "disk full" even though 'btrfs fi df" reports enough room left? linux-btrfs.tebulin
2015-11-18 19:08 ` Hugo Mills [this message]
2015-11-19  0:42   ` Qu Wenruo
2015-11-19  2:16     ` Duncan
2015-11-20 11:39       ` Dmitry Katsubo
2015-11-20 13:21         ` Austin S Hemmelgarn
2015-11-20 13:27           ` Hugo Mills
2015-11-20 13:52             ` Austin S Hemmelgarn
2015-11-20 16:39               ` Dmitry Katsubo
2015-11-19 17:35   ` linux-btrfs.tebulin
2015-11-19 18:28     ` Hugo Mills
2015-11-19 18:45       ` linux-btrfs.tebulin
2015-11-19 18:56         ` linux-btrfs.tebulin
2015-11-19 19:26           ` linux-btrfs.tebulin
2015-11-20  3:14           ` Duncan
2015-11-20  9:38             ` linux-btrfs.tebulin
2015-11-20 10:44               ` Duncan
2015-11-20 14:25             ` Dmitry Katsubo
2015-11-19 20:18       ` Austin S Hemmelgarn
2015-11-19  5:58 ` Roman Mamedov
2015-11-19  8:31   ` Patrik Lundquist
2015-11-19 12:28 ` Austin S Hemmelgarn
2015-11-20  2:11   ` Duncan
2015-11-20 13:13     ` Austin S Hemmelgarn

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=20151118190857.GY24333@carfax.org.uk \
    --to=hugo@carfax.org.uk \
    --cc=linux-btrfs.tebulin@xoxy.net \
    --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