Common Misconfigured HP-UX Resources (April 2006)
The HFS Inode Cache
With the introduction of the Journaled File System (JFS), many systems now use the High Performance
File System (HFS) for the boot file system (/stand) only. Since the JFS inode cache is managed
separately from the HFS inode cache, you may need to adjust the size of your HFS inode cache.
This section addresses the following questions regarding the HFS inode cache:
• What is an inode cache?
• How is the HFS inode cache managed?
• How much memory is required for the HFS inode cache?
• What dependencies are there on the HFS inode cache?
• Are there any guidelines for configuring the HFS inode cache?
What is an Inode Cache?
An inode cache is simply a holding location for inodes from disk. Each inode in memory is a superset
of data that contains the inode from disk. The disk inode stores information for each file, such as the
file type, permissions, timestamps, size of file, number of blocks, and block map. The in-memory
inode stores the on-disk inode information along with overhead used to manage the inode in memory.
This information includes pointers to other structures, pointers used to maintain linked lists, the inode
number, lock primitives, and other related information.
The inode cache is the collection of in-memory inodes with its various linked lists used to manage the
inodes. Once the inode is brought into memory, subsequent access to the inode can be done through
memory without having to read or write it to disk.
One inode cache entry must exist for every file that is opened on the system. If the inode table fills up
with active inodes, the following error will be seen on the console and in the syslog file and the
open() system call will fail:
inode table is full
Once the last close is done on a file, the inode will be put on a free list but it is not necessarily
removed from the cache. The inode cache may contain some files that are closed, so if the file is
reopened a disk access will not occur because the inode is already in memory.
The HFS Inode Cache is a Static Cache
The HFS inode cache is a statically sized table built during bootup. It is simply an array of in-memory
HFS inodes, which is hashed for quick lookups into the table. Inodes are either in use or on the free
list. It is common for the HFS inode cache to appear full since even closed files are maintained in the
HFS inode cache.
4