| United States-English |
|
|
|
![]() |
Installing and Administering NFS Services with 10.20 ACE and HWE: HP 9000 Networking > Chapter 3 Configuring the Cache
File System (CacheFS)Configuring CacheFS |
|
Before you mount a file system, you must decide whether to use CacheFS. CacheFS improves read performance for data that will be read more than once. It does not improve write performance at all. The first time data is read from an NFS-mounted file system, there is actually some overhead while CacheFS writes the data to its local cache. After the data is written to the cache, read performance for the file system is significantly improved. Good choices for cached file systems include man pages and executable programs, which are read multiple times and rarely modified. A bad choice is /var/mail, which is modified frequently but is typically read only once and then thrown away. You cannot use SAM to mount a file system with CacheFS. You can use CacheFS to cache NFS-mounted or automounted NFS file systems. Before you can mount a file system using CacheFS, you must configure a local file system as the cache directory. This section gives instructions for completing the following tasks: For more information on CacheFS, see the following man pages: cfsadmin(1M), fsck_cachefs(1M), mount(1M), mount_cachefs(1M), and cachefsstat(1M).
CacheFS manages its resources most effectively in cases where the entire front file system is dedicated to caching, or in cases where the non-cache portions of the front file system are static, read-only files. CacheFS allows more than one file system to be cached in the same cache. There is no need to create a separate cache directory for each CacheFS mount. In typical usage, you need to run cfsadmin -c only once to create a single cache for all of your CacheFS mounts. For more information, type man 1M cfsadmin at the HP-UX prompt. Before you can mount an NFS file system with CacheFS, you must configure a directory in a local file system as cache. See “To Configure a Local File System as Cache”.
This example NFS-mounts the directory /opt/frame from server nfsserver to the local /opt/frame directory. Now, /opt/frame can be accessed just like any mounted file system. As data in /opt/frame is referenced, it will be copied into /disk2/cache. Further references to the data will access the data on the local disk instead of the data on the remote server. For more information, type man 1M mount at the HP-UX prompt. Before you can automount an NFS file system with CacheFS, you must configure a directory in a local file system as cache. See “To Configure a Local File System as Cache”.
You can specify caching in an NIS automounter map only if all clients who will use the map have their caching directory set up in the same location (/disk2/cache, in the examples). For more information, type man 1M automount at the HP-UX prompt. |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
|||||||||||||||