linux-ext4.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Filipe David Manana <fdmanana@apache.org>
To: Sunil Mushran <sunil.mushran@oracle.com>
Cc: linux-ext4@vger.kernel.org
Subject: Re: question about file space preallocation with fallocate
Date: Mon, 27 Dec 2010 17:57:21 +0000	[thread overview]
Message-ID: <AANLkTinEnRaOEqZM9inVyVYW=hh68BC05f6d4Z6Cp7JF@mail.gmail.com> (raw)
In-Reply-To: <4D18CA33.6050800@oracle.com>

On Mon, Dec 27, 2010 at 5:17 PM, Sunil Mushran <sunil.mushran@oracle.com> wrote:
>
> fallocate() gives users the ability to allocate space instantly. One way
> to compare would be to time just fallocate() with another program
> writing zeros for that length.
>
> But that's not the aim of the syscall. The aim is to allow the fs to
> allocate
> the space in as large chunks as possible to allow for better read
> performance.
>
> If you don't do fallocate() and allow writes to allocate in small chunks,
> as you are doing, the allocations on disks could be interleaved in face of
> multiple processes doing the same. Fragmented allocations can only hurt
> read performance.
>

Thanks for the clarification Sunil. But preallocation of blocks
shouldn't also improve write operations? Since each write operation
will no longer cause the OS/filesystem to allocate blocks for the
file, therefore should be faster.

Also, any particular advice for improving write performance when all
the writes are done in append-only fashion?

-- 
Filipe David Manana,
fdmanana@gmail.com, fdmanana@apache.org

"Reasonable men adapt themselves to the world.
 Unreasonable men adapt the world to themselves.
 That's why all progress depends on unreasonable men."
--
To unsubscribe from this list: send the line "unsubscribe linux-ext4" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

  reply	other threads:[~2010-12-27 17:57 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-12-27 14:47 question about file space preallocation with fallocate Filipe David Manana
2010-12-27 17:17 ` Sunil Mushran
2010-12-27 17:57   ` Filipe David Manana [this message]
2010-12-27 19:11     ` Sunil Mushran
2011-01-03 17:07   ` Eric Sandeen

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='AANLkTinEnRaOEqZM9inVyVYW=hh68BC05f6d4Z6Cp7JF@mail.gmail.com' \
    --to=fdmanana@apache.org \
    --cc=linux-ext4@vger.kernel.org \
    --cc=sunil.mushran@oracle.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;
as well as URLs for NNTP newsgroup(s).