System Administration Guide, Volume I

How to Delete a Cached File System

  1. Become superuser.

  2. Unmount the cached file system.


    # umount mount-point
    

    mount-point specifies the cached file system that you want to delete.

  3. Determine the cache ID from the cfsadmin -l output, as follows:


    # cfsadmin -l cache-directory
    cfsadmin: list cache FS information
       maxblocks     90%
       minblocks      0%
       threshblocks  85%
       maxfiles      90%
       minfiles       0%
       threshfiles   85%
       maxfilesize    3MB
    cache-ID
    #
  4. Delete a cached file system from a specified cache.


    # cfsadmin -d cache-id cache-directory
    

    cache-id

    Indicates the name of the cached file system, which is the last line of the cfsadmin -l output. See "How to Display Information About Cached File Systems" for more information. You can delete all the cached file systems in a particular cache by specifying all for cache-id.

    cache-directory

    Specifies the directory where the cache resides. 

  5. Verify that the file system has been deleted.

    The cache ID of the file system you just deleted should be missing from the output of the following command. Refer to cfsadmin(1M) for more information about the fields specified in the command output.


    # cfsadmin -l cache-directory
    cfsadmin: list cache FS information
       maxblocks     90%
       minblocks      0%
       threshblocks  85%
       maxfiles      90%
       minfiles       0%
       threshfiles   85%
       maxfilesize    3MB
    # 

Examples--Deleting a Cached File System

The following example unmounts a cached file system and deletes the cached file system from the cache.


# umount /docs
# cfsadmin -d merlin:_docs:_docs /local/mycache

The following example deletes all the cached file systems in the /local/mycache cache. This also deletes the cache.


# cfsadmin -d all /local/mycache