System information

Opening a file from a shared file system for direct I/O will automatically bypass the cache. This is
because this type of access must be direct to the server.
Opening a file from a shared file system for writing will not work on NFS version 2 and 3. The
protocols of these versions do not provide sufficient coherency management information for the client
to detect a concurrent write to the same file from another client.
As such, opening a file from a shared file system for either direct I/O or writing will flush the cached
copy of the file. FS-Cache will not cache the file again until it is no longer opened for direct I/O or
writing.
Furthermore, this release of FS-Cache only caches regular NFS files. FS-Cache will not cache
directories, symlinks, device files, FIFOs and sockets.
10.4. Set t ing Cache Cull Limit s
The cachefi l esd daemon works by caching remote data from shared file systems to free space on
the disk. This could potentially consume all available free space, which could be bad if the disk also
housed the root partition. To control this, cachefi l esd tries to maintain a certain amount of free
space by discarding old objects (i.e. accessed less recently) from the cache. This behavior is known
as cache culling.
Cache culling is done on the basis of the percentage of blocks and the percentage of files available
in the underlying file system. There are six limits controlled by settings in
/etc/cachefi lesd .co nf:
b ru n N% ( p ercen t ag e o f b lo cks) , f ru n N% ( p ercen t ag e of files)
If the amount of free space and the number of available files in the cache rises above both
these limits, then culling is turned off.
b cull N% (p ercen t ag e o f blo cks) , f cull N% (p ercen t ag e o f f iles)
If the amount of available space or the number of files in the cache falls below either of
these limits, then culling is started.
b st op N% ( percen t ag e o f b lo cks) , f st o p N% ( p ercen t ag e o f f iles)
If the amount of available space or the number of available files in the cache falls below
either of these limits, then no further allocation of disk space or files is permitted until culling
has raised things above these limits again.
The default value of N for each setting is as follows:
brun/frun - 10%
bcul l /fcul l - 7%
bsto p/fsto p - 3%
When configuring these settings, the following must hold true:
0 <= bsto p < bcul l < brun < 100
0 <= fsto p < fcul l < frun < 100
These are the percentages of available space and available files and do not appear as 100 minus
the percentage displayed by the d f program.
Red Hat Ent erprise Lin ux 6 St orage Admin ist rat io n G uide
78