CNFS block size

Mark Hittinger bugs at pu.net
Mon Sep 9 03:07:16 UTC 2002



> Jeffrey wrote:
> #define CNFS_BLOCKSIZE  512             /* Unit block size we'll work with */
> What happens if I bump this up to 4k?

Interesting thought but since we are using MMAP to do the I/O the paging
system blocksize is probably more important.

I see we are using madvise() in dbz.c to tell the OS that we are using random
I/O and in cnfs.c we are using madvise() to tell the OS we are sequential.
If we have madvise() that is. :-)

For history we wouldn't want to fault in some extra pages on a read.

For big binary cnfs cycbuff's it would be nice if we could use madvise() to let
the OS fault in a few more sequential pages on a read than normal.  Ditto
for overview ...um... cycbuffs.  Unfortunately madvise() won't let us do that.

For text cnfs cycbuffs we don't really need a lot of extra pages to be faulted
in because the average size of a text article is so small.  It might make more
sense to be able to madvise() random on text cycbuffs.

Along the same lines it would be nice to be able to set a cycbuff to be
madvise() DONTNEED in the case where a cycbuff stores infrequently used groups.

For example we could add another parameter to cycbuff.conf:

cycbuff:CONTROL:/cycbuffs/control:512000:RANDOM       <- tiny articles
cycbuff:MICROSOFT:/cycbuffs/answers:512000:DONTNEED   <- infrequently used
cycbuff:CDIMAGE:/cycbuffs/cdimage:512000:SEQUENTIAL   <- articles > 1 page

Later

Mark Hittinger
bugs at pu.net


More information about the inn-workers mailing list