Saturday, August 18, 2012

How to Reduce file system cache size on Aix to resolve paging issues

By default, AIX is tuned for a mixed workload, and will grow its VMM file cache up to 80% of physical RAM, it is very poor for running any application which does its own cache management.

For most database systems, the ideal solution is to use raw logical volumes. If this is not acceptable, then direct I/O and concurrent I/O should be used. If for some reason this is not possible, then the last solution is to tune the AIX file caches to be less aggressive. 

The four main parameters that should be tuned are the three controlling the size of the persistent file cache (minperm% and maxperm%) used for JFS filesystems, and the client file cache (maxclient%) used by NFS, CDRFS and JFS2 filesystems, and also the lru_file_repage parameter, which influences what pages the VMM page stealing algorithm will steal (present in AIX 5.2 ML4+ and AIX 5.3 ML1+).
numperm% 
Defines the current size of the persistent file cache.
minperm% 
Defines the minimum amount of RAM the persistent file cache may occupy. If numperm% is less than or equal to minperm%, file pages will not be stolen when RAM is required.
maxperm% 
Defines the maximum amount of RAM the persistent file cache may occupy before it is used as the sole source of new pages by the page stealing algorithm. By default, numperm% may exceed maxperm% if there is free memory available. The setting strict_maxperm may be set to one to change maxperm% into a hard limit, guaranteeing numperm% will never exceed maxperm%.
strict_maxperm 
As above, if set to 1, changes maxperm% into a hard limit.
numclient% 
Defines the current size of the client file cache.
maxclient% 
Defines the hard maximum size of the client file cache.
strict_maxclient 
Introduced in 5.2 ML4, allows the changing of maxclient% into a soft limit, similar to strict_maxperm.
lru_file_repage 
Introduced in AIX 5.2 ML4 and AIX 5.3 ML1, this influences the VMM page stealing algorithm. If set to 0, the algorithm will strongly prefer stealing file pages to satisfy memory requests.
Note that maxclient% may never exceed maxperm%. In later versions of vmtune, this is enforced by changing both parameters if necessary.

No comments:

Post a Comment