Re: File system performance, hardware performance, ext3, 3ware RAID1,etc.

From: Linus Torvalds
Date: Fri Feb 13 2004 - 14:57:08 EST




On Fri, 13 Feb 2004, Eric D. Mudama wrote:
>
> This may be a function of the operating system or the filesystem, but
> it isn't necessarilly an artifact of the drives themselves. With both
> read and write caching enabled, random writes will always be faster
> than random reads from the drive perspective.

Well.. Yes and no.

Writes are fundamentally more schedulable, and that's a huge advantage for
throughput, since latency really doesn't matter. Which means that you'll
find a lot of loads that can much more easily get to platter speeds for
writes.

On the other hand, reads are inherently easier on a pure hardware level,
since read-ahead and track buffers are trivial ways to get to true platter
speeds for a lot of reasonable loads.

And the software-visible 512-byte blocking factor just has to be
_incredibly_ painful on a hardware level, and I'd be surprised if there
aren't disks out there already where the actual real physical block-size
is bigger. Which means that I would expect a lot of drives to internally
do read-modify-write cycles for small writes.

And especially in a market where density is often more important than pure
speed, I'd expect hw manufacturers to have a _huge_ bias towards big
blocks on the platter, in order to avoid having to have lots of
inter-sector gaps etc.

So in that kind of schenario, random writes would be clearly slower than
random reads.

> the absolute worst-case write performance should be the same as read
> performance.

That is only true if the disk block-size is smaller than the IO blocksize.
Can somebody fill me in on what modern disks do, especially the
high-density ones?

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