Thread (13 messages) flat view 13 messages, 6 authors, 2012-03-07

Re: [RFC] fadvise: add more flags to provide a hint for block allocation

From: Dave Chinner <david@fromorbit.com>
Date: 2012-03-07 00:51:30
Also in: linux-fsdevel

On Mon, Mar 05, 2012 at 08:50:29PM +0800, Zheng Liu wrote:
Hi list,

Block allocation is a key component of file system.  Every file systems try to
improve the performance with optimizing the block allocation of a file.  But no
matter what file system does, it just guesses what the user expects.  Thus, it
is not very accurate.  fadvise(2) provides a method to let the user to give a
hint to file system.  However, until now, only few flags are provided.  So we
can provide more flags to tell file system how to allocate the blocks for a
file.

For example:
we can add these flags into fadvise(2):
FADV_ALLOC_READ_SEQ
fallocate()
FADV_ALLOC_READ_RANDOM
Allocation can't be optimised as the read pattern cannot be defined.
FADV_ALLOC_WRITE_ONCE
fallocate()
FADV_ALLOC_WRITE_APPEND
chattr +a

Cheers,

Dave.
-- 
Dave Chinner
david@fromorbit.com
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help