public inbox for linux-btrfs@vger.kernel.org
 help / color / mirror / Atom feed
From: Duncan <1i5t5.duncan@cox.net>
To: linux-btrfs@vger.kernel.org
Subject: Re: ERROR: error during balancing '.' - No space left on device
Date: Sun, 23 Mar 2014 12:26:32 +0000 (UTC)	[thread overview]
Message-ID: <pan$a5998$152d4a82$370a3453$dc1d788e@cox.net> (raw)
In-Reply-To: 20140323070144.GG12833@merlins.org

Marc MERLIN posted on Sun, 23 Mar 2014 00:01:44 -0700 as excerpted:

> legolas:/mnt/btrfs_pool2# btrfs balance .
> ERROR: error during balancing '.' - No space left on device

> But:
> # btrfs fi show `pwd`
> Label: btrfs_pool2  uuid: [...]
> 	Total devices 1 FS bytes used 646.41GiB
>       devid 1 size 820.45GiB used 820.45GiB path /dev/mapper/disk2
> # [btrfs fi df `pwd` (unused single metadata/system chunks omitted)]
> Data, single: total=800.42GiB, used=636.91GiB
> System, DUP: total=8.00MiB, used=92.00KiB
> Metadata, DUP: total=10.00GiB, used=9.50GiB
> 
> I can't see how I'm full, and now that I can't run balance to fix
> things, this is making things worse.
> Kernel is 3.14.
> 
> What am I missing?

When it rains, it pours.  What you're missing is that this is now the 
third thread in three days with exactly the same out-of-space-when-there-
appears-to-be-plenty problem, which is well explained and a solution 
presented, along with further discussion, on those threads.

Evidently you haven't read the others, but rather than rewrite a similar 
reply here with exactly the same explanation and fix, I'll just refer you 
to them.

First thread, subject, original poster, message-id, gmane link:

fresh btrfs filesystem, out of disk space, hundreds of gigs free

Jon Nelson <jnelson@jamponi.net>

<CAKuK5J0LyagDYro6Yq7h-p-VjbwrbeuFf9AdNwRNg0jv3bq9QQ@mail.gmail.com>

http://permalink.gmane.org/gmane.comp.file-systems.btrfs/33640


Second thread (same problem altho he chose as a subject a btrfsck error 
that wasn't actually related to it) ...

free space inode generation (0) did not match free space cache
 generation

Hendrik Friedel <hendrik@friedels.name>

<532DD2DC.3030408@friedels.name>

http://permalink.gmane.org/gmane.comp.file-systems.btrfs/33647

Very briefly, from your btrfs fi show:

devid 1 size 820.45GiB used 820.45GiB

That's total size and total of allocated chunks.  They're equal, so 
there's no space left to allocate.  Normally you'd use a balance, but a 
normal balance won't work without some space left to write the new chunks 
it's going to copy the old data/metadata into.  There is however a 
solution, balance filters, using a command something like this (-d for 
data only since df says that's what has the extra chunks that need freed, 
usage=percent-full):

btrfs balance start -dusage=5 `pwd`

Tweak the N in usage=N as needed.

The explanation for all that is in the other threads.  If that doesn't 
work (tho it most likely will), there's other solutions available, see 
the no-space discussion in the FAQ on the wiki, again as linked in the 
other threads.

-- 
Duncan - List replies preferred.   No HTML msgs.
"Every nonfree program has a lord, a master --
and if you use the program, he is your master."  Richard Stallman


      parent reply	other threads:[~2014-03-23 12:27 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-03-23  7:01 ERROR: error during balancing '.' - No space left on device Marc MERLIN
2014-03-23 11:47 ` Hugo Mills
2014-03-23 16:20   ` Marc MERLIN
2014-03-23 16:28     ` Hugo Mills
2014-03-23 17:03       ` Marc MERLIN
2014-03-23 17:34         ` Hugo Mills
2014-03-23 19:10           ` Marc MERLIN
2014-03-23 21:20             ` Marc MERLIN
2014-03-23 12:26 ` Duncan [this message]

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='pan$a5998$152d4a82$370a3453$dc1d788e@cox.net' \
    --to=1i5t5.duncan@cox.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