Re: Integration of COSS into the modio branch

From: <adrian@dont-contact.us>
Date: Sat, 12 Feb 2000 08:15:27 +0800

On Sat, Feb 12, 2000, Henrik Nordstrom wrote:
> adrian@creative.net.au wrote:
>
> > Ignoring aufs, give my modio stuff a go.
>
> /home/henrik/SRC/squid/SF/hno-devel/src/fs/coss/store_io_coss.c: In
> function `storeCossCreate':
> /home/henrik/SRC/squid/SF/hno-devel/src/fs/coss/store_io_coss.c:114:
> warning: assignment of read-only member `swap_dirn'
> /home/henrik/SRC/squid/SF/hno-devel/src/fs/coss/store_io_coss.c:115:
> warning: passing arg 1 of `storeCossAllocate' discards `const' from
> pointer target type

Yup.

> cache_dir -1 /tmp/coss 100
> coredump_dir /tmp
> cache_swap_log /tmp
>
> A quick check with a debugger reveals that store_dirs_rebuilding is
> always 1. The logic in storeCossDirRebuild looks very fishy in all cases
> except when there exists a clean log file...
>
> * If no (or empty) log file then nothing at all is done. It should at
> least call storeRebuildComplete
>
> * If not clean, then storeRebuildComplete is called, but the temporary
> log opened in storeCossDirOpenTmpSwapLog is still open..
>
> Added a call to storeRebuildComplete to get things going (commited), and
> now COSS seems to swap out objects fine..
>
> However, swapins seems to have some major problems..
>
> 2000/02/12 00:49:03| WARNING: failed to unpack swapfile meta data
> 2000/02/12 00:49:04| WARNING: failed to unpack swapfile meta data
> 2000/02/12 00:49:04| WARNING: failed to unpack swapfile meta data
>
> A quick inspection of the data file reveals that nothing got written to
> it. Perhaps it only stayed in memory and got lost when I restarted
> Squid... I only tested with a very light workload of a few 100 KB of
> data at most..
>

Ah. Ok, coss requires you to call storeCreate() with the full object
in existance. Which is why I did the maxobjsize hack again in this tree.

You need to give coss a max object size, or it won't work well. Also,
it won't swap out until a membuf is full, if I read the code right.

It seems to work fine for me :), commit the changes you feel are needed to
fix the rebuilding logic (or lack thereof) and I'll keep testing.
There's a few problems under heavy load with the code that exists atm,
so I'll keep hacking at the code a little more.

Adrian
Received on Fri Feb 11 2000 - 17:18:26 MST

This archive was generated by hypermail pre-2.1.9 : Tue Dec 09 2003 - 16:12:21 MST