On 02/03/2013 08:31 PM, Amos Jeffries wrote:
>> On 2/3/2013 8:29 PM, Alex Rousskov wrote:
>>> To be consistent with ufs, we should probably change rock behavior from
>>> initializing the database to doing nothing if the configured database
>>> directory already exists. Like ufs, rock will rely on directory
>>> existence for that test (regardless of what may be inside that
>>> configured directory). In other words, squid-z is not "validate and
>>> initialize" but "initialize if the configured directory is not there".
>>>
>>> Any objections to that rock change?
> Absolutely none. Start by making both perform an existence check before
> doing *anything*.
> * initialize if it does not exist yet
Will do.
> * optionally perform validation + repair if something does.
This should not be the default behavior, IMO. Since validation may take
a long time, and since many startup scripts run squid-z today simply
because they look for wrong directories, we should not add an hour-long
operation to all those scripts.
> UFS seems to scan the directory structure and create missing
> sub-directories. Omiting the file corruption tests. We should probably
> add these now that they are possible.
>
> Rock should probably scan the potentially corrupt database and try to
> drop/erase individual corrupt entries before deciding whether to
> completely re-initialize the DB.
Perhaps this validation can be triggered by squid -z -S? I am not
volunteering for this project at this time, but I think patches
implementing the cache_dir validation in -z mode should be welcomed,
especially if motivated by deployment use cases.
Thank you,
Alex.
Received on Mon Feb 04 2013 - 05:06:49 MST
This archive was generated by hypermail 2.2.0 : Tue Feb 05 2013 - 12:00:05 MST