[OpenAFS] AFS client cache investigation

Benjamin Chardi Marco Benjamin.Chardi.Marco@cern.ch
Tue, 15 Oct 2002 16:04:32 +0200 (CEST)


Dear friends,
I am making an investigation about fine-tuning afs client cache manager   
and I need your help. The afs configuration parameters that I use are 
cache size, chunk size and stat . I control them from afsd program and I 
follow these steps to change the afs configuration; 

1-Stop afs /etc/rc.d/init.d/afs stop
2-Change afsd parameters in initiation script /etc/sysconfig/afs
3-Clean the cache, delete all the files in /usr/vice/cache/
4-Star afs /etc/rc.d/init.d/afs start

For each afs configuration I run a test script. It selects randomly one of 
80000 files that are in different servers and copy it. This random 
selection is repeated 200000 times to be sure that the local cache is 
full.

When the script ends from afsmonitor program I get the number of files 
found in local cache and number of files not found during the script work. 
I use the ratio between this parameters (number of files found in local 
cache divided by number of files not found in local cache = 
dcacheHits/dcacheMisses) like a test parameter: I follow the evolution of 
this ratio when I change the afs configuration parameters like cache size, 
chunck size and stat.

For variations of cache size (256MB ? 1GB) and chunk size (2^12 - 2^28), 
the evolution of this ratio was logical. If I increase this configuration 
parameters the ratio is going up (it means that I found more files in 
local cache and I make less calls to the servers). It is logical because 
if I have bigger cache size I can store locally more files and I find more 
files locally->the ratio grows. 

The problem comes when we study the stat parameter (with cache size = 1GB 
and chunk size = 2^18 fixed). If I increase the stat parameter this ratio 
is going down!!! I do not understand why the ratio is going down???. If I 
have more stat entries to allocate in memory machine's the status of the 
files in cache directory, this ratio must go up!! Is this a logical 
result?. Is my test script not good to study the start parameter? .

Waiting for an answer. B Chardi.