Possible O_DIRECT problems ?

Dave Jones (davej@suse.de)
Fri, 21 Dec 2001 00:08:06 +0000


Andrea, lk,
I just experimented with O_DIRECT in conjunction with fsx,
and the results aren't pretty.

Over NFS it survives around 921 operations, all local filesystems
(ext2,ext3,reiser tested) just 6 operations.
I've put the source to a modified fsx at
http://www.codemonkey.org.uk/cruft/fsx-odirect.c

It's possible I've done something wrong here, so look it over.
Just adding O_DIRECT flag to open() should be all thats necessary
correct ?

Also note, that by changing the flags on line 988 to have O_DIRECT
also, we get different failure type.

So, did I get the usage of O_DIRECT correct and find some bugs,
or have I had a little too much xmas spirits already ? 8-)

Dave.

-- 
| Dave Jones.                    http://www.codemonkey.org.uk
| SuSE Labs .
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/