[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <E1H4s8d-0006he-0k@w-gerrit.beaverton.ibm.com>
Date: Wed, 10 Jan 2007 21:06:06 -0800
From: Gerrit Huizenga <gh@...ibm.com>
To: Andrew Morton <akpm@...l.org>
cc: Aubrey <aubreylee@...il.com>, "Hua Zhong" <hzhong@...il.com>,
"Hugh Dickins" <hugh@...itas.com>, linux-kernel@...r.kernel.org,
hch@...radead.org, kenneth.w.chen@...el.com, torvalds@...l.org,
mjt@....msk.ru
Subject: Re: O_DIRECT question
On Wed, 10 Jan 2007 20:51:57 PST, Andrew Morton wrote:
> On Thu, 11 Jan 2007 10:57:06 +0800
> Aubrey <aubreylee@...il.com> wrote:
>
> > Hi all,
> >
> > Opening file with O_DIRECT flag can do the un-buffered read/write access.
> > So if I need un-buffered access, I have to change all of my
> > applications to add this flag. What's more, Some scripts like "cp
> > oldfile newfile" still use pagecache and buffer.
> > Now, my question is, is there a existing way to mount a filesystem
> > with O_DIRECT flag? so that I don't need to change anything in my
> > system. If there is no option so far, What is the right way to achieve
> > my purpose?
>
> Not possible, basically.
>
> O_DIRECT reads and writes must be aligned to the device's block size
> (usually 512 bytes) in memory addresses, file offsets and read/write request
> sizes. Very few applications will bother to do that and will hence fail if
> their files are automagically opened with O_DIRECT.
Actually, technically possible. We heard from some application people
that Sun/Solaris has this option. Good if the application is the only
one using the filesystem. Supposedly there were large apps which used
lots of filesystems more or less exclusively and this option made people
happy.
Although before Linus says it, I guess crack makes people happy, too. ;)
gerrit
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists