21.02.2013 Views

AIX 5L Problem Determination - IBM Redbooks

AIX 5L Problem Determination - IBM Redbooks

AIX 5L Problem Determination - IBM Redbooks

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

The VMM tries to anticipate the future need for pages of a sequential file by<br />

observing the pattern in which a program is accessing the file. When the program<br />

accesses two successive pages of the file, the VMM assumes that the program<br />

will continue to access the file sequentially, and the VMM schedules additional<br />

sequential reads of the file. This is called Sequential-Access Read Ahead. These<br />

reads are overlapped with the program processing, and will make the data<br />

available to the program sooner than if the VMM had waited for the program to<br />

access the next page before initiating the I/O. The number of pages to be read<br />

ahead is determined by two VMM thresholds:<br />

minpgahead Number of pages read ahead when the VMM first detects<br />

the sequential access pattern. If the program continues to<br />

access the file sequentially, the next read ahead will be<br />

for 2 times minpgahead, the next for 4 times minpgahead,<br />

and so on until the number of pages reaches<br />

maxpgahead.<br />

maxpgahead Maximum number of pages the VMM will read ahead in a<br />

sequential file.<br />

If the program deviates from the sequential-access pattern and accesses a page<br />

of the file out of order, sequential read ahead is terminated. It will be resumed<br />

with minpgahead pages if the VMM detects a resumption of sequential access by<br />

the program. The values of minpgahead and maxpgahead can be set with the<br />

vmtune command.<br />

To increase write performance, limit the number of dirty file pages in memory,<br />

reduce system overhead, and minimize disk fragmentation. The file system<br />

divides each file into 16-KB partitions. The pages of a given partition are not<br />

written to disk until the program writes the first byte of the next 16-KB partition. At<br />

that point, the file system forces the four dirty pages of the first partition to be<br />

written to disk. The pages of data remain in memory until their frames are<br />

reused, at which point no additional I/O is required. If a program accesses any of<br />

the pages before their frames are reused, no I/O is required.<br />

If a large number of dirty file pages remains in memory and does not get reused,<br />

the sync daemon writes them to disk, which might result in abnormal disk<br />

utilization. To distribute the I/O activity more efficiently across the workload,<br />

write-behind can be turned on to tell the system how many pages to keep in<br />

memory before writing them to disk. The write-behind threshold is on a per-file<br />

basis, which causes pages to be written to disk before the sync daemon runs.<br />

The I/O is spread more evenly throughout the workload.<br />

There are two types of write-behind: Sequential and random. The size of the<br />

write-behind partitions and the write-behind threshold can be changed with the<br />

vmtune command.<br />

Chapter 10. Performance problem determination 259

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!