xfs
[Top] [All Lists]

Re: vim file write mode on journaling fs.

To: Russell Cattelan <cattelan@xxxxxxxxxxx>
Subject: Re: vim file write mode on journaling fs.
From: Bram Moolenaar <Bram@xxxxxxxxxxxxx>
Date: Sat, 11 Aug 2001 20:48:01 +0200
Cc: Seth Mos <knuffie@xxxxxxxxx>, Linux XFS Mailing List <linux-xfs@xxxxxxxxxxx>
In-reply-to: <3B75549D.96EEE5EB@thebarn.com>
Sender: owner-linux-xfs@xxxxxxxxxxx
Russell Cattelan wrote:

> You have the scenario backwards, the idea of delayed allocation/write is
> to reduce the amount of disk activity and to aggregate disk writes together
> thus by making disk transfers more efficient.

Making disk I/O more efficient is only relevant if there is quite a bit of I/O
going on.  In the (many) periods with little disk I/O delaying writes doesn't
make much sense.  This is especially relevant on a workstation.

> The is no way for the kernel/filesystem to predict the type of IO a user app
> is going to do, streaming, random, fast random slow random... the kernel and
> FS make best guess real world average behavior predictions. Everything is
> tune able of course but that requires the person running the app understands
> the app's io behavior.

What tools do I have that indicate to the FS how it should handle the data I
have written?  Can I somehow tell it to flush my data soon, but not as drastic
as syncing?

> > It's certainly worth the effort to implement this.
> 
> It is implemented it's called O_SYNC.

Where is this documented?  I don't have it on my FreeBSD system, is this Linux
specific?

> > The tests done by Seth
> > show that this is a real, existing problem.
> 
> Every file system that does buffering has this problem XFS included.

That's not true.  Only filesystems with delayed data writes have this problem.
a "normal" file system doesn't do reordering of writes and/or doesn't delay
writing dirty data blocks.

> > Don't look at this from the point of view of a person that knows what
> > "delayed allocation/write" means, look at it from the point of view of a
> > user.
> 
> Maybe so but as a user sometimes you must understand your system to
> understand why it does things, and not assume it's a bug.

OK.  Since I now understand how it works I will recommend every user NOT to
use this kind of filesystem.  The risk of losing your work is too big.
Perhaps that's why FreeBSD doesn't use a journalling file system.

-- 
ARTHUR:        I command you as King of the Britons to stand aside!
BLACK KNIGHT:  I move for no man.
                                  The Quest for the Holy Grail (Monty Python)

 ///  Bram Moolenaar -- Bram@xxxxxxxxxxxxx -- http://www.moolenaar.net  \\\
(((   Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim   )))
 \\\  Help me helping AIDS orphans in Uganda - http://iccf-holland.org  ///


<Prev in Thread] Current Thread [Next in Thread>