From: Hugo Mills <hugo@carfax.org.uk>
To: ching <lsching17@gmail.com>, cwillu <cwillu@cwillu.com>,
Felix Pepinghege <postfach@pepinghege.net>,
"linux-btrfs@vger.kernel.org" <linux-btrfs@vger.kernel.org>
Subject: Re: Why btrfs inline small file by default?
Date: Tue, 30 Oct 2012 22:19:47 +0000 [thread overview]
Message-ID: <20121030221947.GC11422@carfax.org.uk> (raw)
In-Reply-To: <20121030221412.GB11422@carfax.org.uk>
[-- Attachment #1: Type: text/plain, Size: 1607 bytes --]
On Tue, Oct 30, 2012 at 10:14:12PM +0000, Hugo Mills wrote:
> On Wed, Oct 31, 2012 at 05:40:25AM +0800, ching wrote:
> > On 10/30/2012 08:17 PM, cwillu wrote:
> > >>> If there is a lot of small files, then the size of metadata will be
> > >>> undesirable due to deduplication
> > >>
> > >> Yes, that is a fact, but if that really matters depends on the use-case
> > >> (e.g., the small files to large files ratio, ...). But as btrfs is designed
> > >> explicitly as a general purpose file system, you usually want the good
> > >> performance instead of the better disk-usage (especially as disk space isn't
> > >> expensive anymore).
> > > As I understand it, in basically all cases the total storage used by
> > > inlining will be _smaller_, as the allocation doesn't need to be
> > > aligned to the sector size.
> > >
> >
> > if i have 10G small files in total, then it will consume 20G by default.
>
> If those small files are each 128 bytes in size, then you have
> approximately 80 million of them, and they'd take up 80 million pages,
> or 320 GiB of total disk space.
Sorry, to make that clear -- I meant if they were stored in Data.
If they're inlined in metadata, then they'll take approximately 20 GiB
as you claim, which is a lot less than the 320 GiB they'd be if
they're not.
Hugo.
--
=== Hugo Mills: hugo@... carfax.org.uk | darksatanic.net | lug.org.uk ===
PGP key: 515C238D from wwwkeys.eu.pgp.net or http://www.carfax.org.uk
--- I always felt that as a C programmer, I ---
was becoming typecast.
[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 828 bytes --]
next prev parent reply other threads:[~2012-10-30 22:19 UTC|newest]
Thread overview: 26+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-10-30 11:04 Why btrfs inline small file by default? ching
2012-10-30 12:04 ` Felix Pepinghege
2012-10-30 12:17 ` cwillu
2012-10-30 21:40 ` ching
2012-10-30 22:14 ` Hugo Mills
2012-10-30 22:19 ` Hugo Mills [this message]
2012-10-30 23:47 ` ching
2012-10-31 0:12 ` David Sterba
2012-10-31 21:07 ` ching
2012-10-31 0:18 ` cwillu
2012-10-31 8:48 ` Ahmet Inan
2012-10-31 9:39 ` cwillu
2012-10-31 10:48 ` Ahmet Inan
2012-10-31 10:55 ` Michael Kjörling
2012-10-31 11:10 ` Ahmet Inan
2012-10-31 10:57 ` cwillu
2012-10-31 11:56 ` Michael Kjörling
2012-10-31 13:27 ` Ahmet Inan
2012-10-31 13:44 ` Roman Mamedov
2012-10-31 21:05 ` ching
2012-10-30 22:16 ` cwillu
2012-10-30 23:41 ` ching
2012-10-30 21:39 ` ching
2012-10-30 12:11 ` Felix Pepinghege
2012-10-30 12:13 ` Mitch Harder
2012-10-30 16:38 ` David Sterba
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=20121030221947.GC11422@carfax.org.uk \
--to=hugo@carfax.org.uk \
--cc=cwillu@cwillu.com \
--cc=linux-btrfs@vger.kernel.org \
--cc=lsching17@gmail.com \
--cc=postfach@pepinghege.net \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.