Published by carla on 10 Jun 2008 at 12:04 pm
Aix - Parâmetros de kernel
Alguns parâmetros de kernel do Aix:
Parameters:
mempools
Specifies the number of memory pools that the system real memory is split into.
Memory pools
The mempools value is used to subdivide the memory into pools. The parameter
mempools has a range from 1 (one) to, but not more than, the value of the
number of CPUs in the system. For example, if there are four CPUs in a system,
then the maximum value of mempools is 4 (four). Setting the value to 0 (zero),
restores the default number. In some circumstances, such as when most, but not
all, of the system memory is in use, better performance can be obtained by
setting this value to 1 (one).
Reference:
Aix 5L Performance Tools Handbook (SG24-6039-01)- Page 232
npskill
Specifies the number of free paging-space pages at which the operating system begins killing processes. If the npskill threshold is reached, a SIGKILL signal is sent to the youngest process. Processes that are handling SIGDANGER or processes that are using the early page-space allocation (paging space is allocated as soon as memory is requested) are exempt from being killed. The formula to determine the default value of npskill is as follows:
npskill = maximum (64, number_of_paging_space_pages/128)
The npskill value must be greater than zero and less than the total number of paging space pages on the system. It can be changed with the command vmo -o npskill=value.
Purpose:
Specifies the number of free paging-space pages at which the operating system begins killing processes.
Values:
- Default: MAX (64, number of paging space pages/128).
- Range: 0 to total number of paging space pages on the system .
- Type: Dynamic
Diagnosis:
N/A
Tuning
Increase the value if you experience processes being killed because of low paging space.
Refer To:
Values for the npswarn and npskill parameters
npsrpgmax
Purpose:
Specifies the number of free paging space blocks at which the Operating System stops freeing disk blocks on pagein of Deferred Page Space Allocation Policy pages.
Values:
- Default: MAX(1024, npswarn*2).
- Range: 0 to total number of paging space blocks in the system.
Diagnosis:
N/A
Tuning:
N/A
npsrpgmin
Purpose:
Specifies the number of free paging space blocks at which the Operating System starts freeing disk blocks on pagein of Deferred Page Space Allocation Policy pages.
Values:
- Default: MAX(768, npswarn+(npswarn/2)).
- Range: 0 to total number of paging space blocks in the system.
Diagnosis:
N/A
Tuning:
N/A
npsscrubmax
Purpose:
Specifies the number of free paging space blocks at which the Operating System stops Scrubbing in memory pages to free disk blocks from Deferred Page Space Allocation Policy pages.
Values:
- Default: MAX(1024, npsrpgmax).
- Range: 0 to total number of paging space blocks in the system.
Diagnosis:
N/A
Tuning:
N/A
npsscrubmin
Purpose:
Specifies the number of free paging space blocks at which the Operating System starts Scrubbing in memory pages to free disk blocks from Deferred Page Space Allocation Policy pages.
Values:
- Default: MAX(768, npsrpgmin).
- Range: 0 to total number of paging space blocks in the system.
Diagnosis:
N/A
Tuning:
N/A
npswarn
Specifies the number of free paging-space pages at which the operating system begins sending the SIGDANGER signal to processes. If the npswarn threshold is reached and a process is handling this signal, the process can choose to ignore it or do some other action such as exit or release memory using the disclaim() subroutine.
The value of npswarn must be greater than zero and less than the total number of paging-space pages on the system. It can be changed with the command vmo -o npswarn=value.
Purpose:
Specifies the number of free paging-space pages at which the operating system begins sending the SIGDANGER signal to processes.
Values:
- Default: MAX (512, 4*npskill)
- Range: 0 to total number of paging space pages on the system.
- Type: Dynamic
Diagnosis:
N/A
Tuning:
Increase the value if you experience processes being killed because of low paging space.
Refer To:
Values for the npswarn and npskill parameters
numpsblks
11-28-02, 01:40
prog_log :- It is used to find out if the dump was due to a hardware
problem.
vmker :- For finnding out free paging space. Nowadays this command is not
used as with time
the offset of free_paging_space/total_paging_space has changed.
The command od
vmker 16 used to be used to look at total paging space and free paging
space but
the field values have changed. It is easier to use the vmm
command to look at the vmker
data. The numpsblks field is the number of total paging space
blocks.
The psfreeblks is the free paging space blocks.
Fonte: http://www.dbforums.com/archive/index.php/t-579015.html
http://download-uk.oracle.com/docs/html/A97297_01/appa_aix.htm
MINFREE The minimum free-list size. If the free-list space in the buffer falls below this size, the system uses page stealing to replenish the free list.
MAXFREE The maximum free-list size. If the free-list space in the buffer exceeds this size, the system stops using page stealing to replenish the free list.
MINPERM The minimum number of permanent buffer pages for file I/O.
MAXPERM The maximum number of permanent buffer pages for file I/O.
pinnable_frames:
| Memory environment variables | Description |
| DR_MEM_SIZE_REQUEST=N | Size of memory requested in megabytes. N is a decimal value. |
| DR_MEM_SIZE_COMPLETED=N | Number of megabytes that were successfully added or removed. N is a decimal value. |
| DR_FREE_FRAMES=N | Number of free frames currently in the system. Each frame is a 4 KB page. N is a 32-bit hexadecimal value. |
| DR_PINNABLE_FRAMES=N | Total number of pinnable frames currently in the system. Each frame is a 4 KB page. N is a 32-bit hexadecimal value. |
| DR_TOTAL_FRAMES=N | Total number of frames in the system. Each frame is a 4 KB page. N is a 32-bit hexadecimal value. |
Fonte: Redbook: SG24-7039-02 - Partitioning Implementations for IBMEserver p5 Servers, Pag 166.
Maxperm: maxperm influences paging behavior. Paging frees memory by copying the “least recently used” memory to disk for temporary storage. Tune maxperm to keep as much of the database in memory as possible when the system pages. The default setting is usually not optimum if the system pages as it favors paging out the database first.
The initial maxperm setting depends on whether the database filesystem resides on JFS or JFS2. For JFS, I automatically change the default “maxperm/maxclient” as above. For JFS2, I recommend using the defaults, and defer tuning to when the system is running a representative workload. The reason is that AIX classifies JFS and JFS2 memory differently. JFS is controlled by “maxperm”, which is a “soft” limit and more forgiving if set too low. JFS2, on the other hand, is controlled by “maxclient”, which is a “hard” limit. If set incorrectly, performance can be degraded. See “maxclient” section for JFS2.
When the system is under load, you can optimize the “maxperm” setting as follows. But first a little background. AIX classifies memory either as persistent or working storage. Persistent storage includes file cache, executables, and metadata. Working storage includes the database. Target amount of memory for persistent storage when the system is paging is the “maxperm” setting. (Note if the system is not paging, the maxperm setting is mostly ignored.) The default “maxperm” value of 80% favors paging out the database first, which degrades performance. In addition, the actual persistent memory requirements are typically much lower (20-50%).
The tuning methodology involves finding the actual persistent memory used when the system is under load (numperm). Then set “maxperm” to 5% below that value.
maxperm = numperm% - 5%.
(Note: be sure to set maxclient=maxperm. See “maxclient” below for more info.)
There are multiple commands for displaying memory usage. Here are two that I use.
AIX 5.1: “/usr/samples/kernel/vmtune | grep numperm”
AIX 5.2: “vmstat -v | grep numperm”
If you don’t have root access to run vmtune, you can use a different approach. Use vmstat “avm” column to estimate the size of the working storage. Calculate numperm% as follows
numperm% = 100% - “working storage%” = 100% - (avm *100 / total memory)
Note “avm” is in measured in 4k pages, so you’ll have to convert this number to the same units as total memory.
maxclient: A subgrouping of persistent memory. As such, “maxclient” is always less than or equal to “maxperm” (I set “maxclient=maxperm”).
The “maxclient” value sets the maximum amount of memory used by its members: JFS2, NFS, CDROM and Veritas file systems. The “maxclient” value is a “hard” limit, which is always enforced.
The importance is that JFS2 has a “hard” limit, while JFS does not. It’s better to leave the JFS2 as default until the system can be tuned while running a representative load. Setting “maxclient” too low can degrade JFS2 performance.
Tune the”maxclient” with the system under load. Use the “maxperm” tuning procedure for setting “maxclient”, and set “maxclient” equal to “maxperm”. If you want to be more precise, you can use the “svmon -G” command to view the amount of memory used by client storage. It’s shown under the “clnt” column (”in use”).
# svmon -G
size inuse free pin virtual
memory 131072 129422 1650 11704 50091
pg space 131072 4279
work pers clnt lpage
pin 11704 0 0 0
in use 47052 76146 6224 0
The svmon command also shows the working storage under the “work” column. It all comes together as follows:
Total memory = free+”working”+”persistent”
= free+work+(pers+clnt)
= 1650+47052+(76146+6224) = 1331072
Reference: http://users.ca.astound.net/baspence/AIXtip/AIX5_Initial_Tuning.htm
