> I miss your point about synchronous, with hundreds of clients doing > small reads against a 10TB database, the benefit of pushing them through > the page cache isn't obvious. No particular data are in memory long > enough to have much chance of being shared, so it looks like overhead to > me. Feel free to educate me.

There is a difference between being synchronous and not going throughthe page cache, although in Linux we don't really have the distinction.

> I certainly DO want to put more users per server, and direct I/O has > proven itself in actual use. I'm not sure why you think the double copy > is a good thing, but I have good rea$on to want more users per server.> > Alan: point on MAP_SHARED taken.

BTW, Alan's point on MAP_SHARED is just that you can have the mmapregion and the page cached region be one and the same. You still aren'tdoing direct I/O.

Maybe that is ultimately what you want.

It is rare to see direct I/O perform better when you use it as normalfile I/O (e.g. don't perform your own caching and scheduling) but if youreally do measure improvements, and if you never reaccess the data (andthus the lack of cache is not a problem), then by all means use it.