performance of O_DIRECT on md/lvm
A message that is not in the archive (sent off-list or not yet received): [email protected]
Quoted 7 lines · [email protected] writes:
Quoted 1 line · In article <[email protected]> you wrote:
I think an optional readahead mode for
O_DIRECTwould be useful.I disagree.
O_DIRECTsays "do not cache. period. I know what I'm doing" and the kernel should respect that imho. After all we havesys_readaheadfor the other part...
Problem with sys_readahead is that it doesn't work for big IO sizes. e.g. you read in big blocks. You have to do readahead(next block); read(directfd, ..., big-block);
The readahead comes to early in this case; it would be better if it is done in the middle of read of big-block based on the request size. Otherwise you risk additional seeks when you overflow the 'read window', which is all to easy this way.
-Andi