Linux Btrfs filesystem development
 help / color / mirror / Atom feed
From: "Lakshmipathi.G" <lakshmipathi.g@giis.co.in>
To: Qu Wenruo <quwenruo@cn.fujitsu.com>
Cc: dsterba <dsterba@suse.cz>, btrfs <linux-btrfs@vger.kernel.org>
Subject: Re: btrfs-convert: whats minimum free space requirement?
Date: Fri, 9 Jun 2017 12:58:16 +0530	[thread overview]
Message-ID: <20170609072816.GA7920@giis.co.in> (raw)
In-Reply-To: <6588ee10-82fe-56aa-3079-955d97a674fd@cn.fujitsu.com>

On Fri, Jun 09, 2017 at 01:35:12PM +0800, Qu Wenruo wrote:
> >ex: Like 5% of ext3/4 free space is needed for
> >btrfs-convert to succeed?
> 
> That's hard to say.
> 
> It's not only dependent on how much free space is here, but also how
> continuous the free space is.
> 
> In convert, it needs the following continuous space at least:
> 
> 1) 64K for temporary btrfs super block
> 2) 4M for system chunk
> 3) 32M for metadata chunk.
> 
> Further more, we want to keep chunks at reasonable size, that's to say we
> want each used data space on old fs is covered by a chunk >= 32M.
> 
> For worst case, if the free space in old fs is so scattered, either we can't
> find continuous for sys/meta chunk, or used data space is so scattered that
> we can't find free space after rounding up data chunks, then we can't do
> convert.
> 
> Thanks,
> Qu

Thanks for the details, Qu.

I was thinking about adding a free-space check (based on total blocks/free block
stat from source superblock) before btrfs-convert begins, looks like its more 
complex than i thought. 

Cheers.
Lakshmipathi.G

  parent reply	other threads:[~2017-06-09  7:29 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-06-09  5:19 btrfs-convert: whats minimum free space requirement? Lakshmipathi.G
     [not found] ` <6588ee10-82fe-56aa-3079-955d97a674fd@cn.fujitsu.com>
2017-06-09  7:28   ` Lakshmipathi.G [this message]
     [not found]     ` <bda5cebd-0683-53f9-6edb-b7f3093b1ed9@cn.fujitsu.com>
2017-06-09 13:02       ` Lakshmipathi.G

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=20170609072816.GA7920@giis.co.in \
    --to=lakshmipathi.g@giis.co.in \
    --cc=dsterba@suse.cz \
    --cc=linux-btrfs@vger.kernel.org \
    --cc=quwenruo@cn.fujitsu.com \
    /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