Information Technology Reference
In-Depth Information
To perform a consistency check on demand, use the
cfsadmin -s
followed by
a mount point of the cached files system as a command-line argument:
# cfsadmin -s /home
#
Managing a Cache Log
The
cachefslog(1M)
command is used to set up, verify, and halt CacheFS
logging. The
cachefswssize(1M)
command is used to analyze the log to
determine a recommended working set size for the cache. A cache that's too
small will cause access delays and higher network traffic (that is, low cache
hit rate). A cache that's too large will waste file system space.
To set up a CacheFS log, use the
cachefslog
command with the
-f
com-
mand-line argument. Following the
-f
should be the filename to be used for
the log and the name of the directory where the cached file system is mount-
ed (not the name of the cache itself). Using the configuration previously
described to cached file systems mounted at
/home
, the following
cachefslog
command is used to create the
/var/tmp/home_log
file:
# cachefslog -f /var/tmp/home_log /home
/var/tmp/home_log: /home
#
To verify cache logging, use the
cachefslog
command and specify only the
mount point of the cached file system as a command-line argument:
# cachefslog /home
/var/tmp/home_log: /home
#
To halt logging, use the
cachefslog
command with the
-h
command-line
argument followed by the mount point of the cached file system:
# cachefslog -h /home
not logged: /home
#
To determine the appropriate size for the cache, set up CacheFs logging and
allow it to run for an appropriate time period (day, week, and so on) that will
provide a snapshot of the representative work load. Then stop logging and use
the
cachefswssize
with the filename of the log as a command-line argument:
# cachefswssize /var/tmp/home_log
/home
end size: 72k
high water size: 72k