Salesforce

Why More APWs are Needed When Using -directio?

« Go Back

Information

 
TitleWhy More APWs are Needed When Using -directio?
URL Name20687
Article Number000147974
EnvironmentProduct: Progress
Version: 8.x, 9.x
Product: OpenEdge
Version: 10.x, 11.x
OS: UNIX
Question/Problem Description
Why More APWs are Needed When Using -directio?
How does -directio impact APWs?
How does -directio impact writes?
Steps to Reproduce
Clarifying Information
Error Message
Defect Number
Enhancement Number
Cause
Resolution
The reason that more Asynchronous Page Writers (APW) are needed when using the Direct I/O (-directio) startup parameter in UNIX is that the APWs take longer to do the write operations. Because the parameter's write() call locks the process until the data have been written to disk, APWs slow up processing. Meanwhile, more of them are necessary because each APW is doing fewer writes.

An APW is a background process whose job is to write updated database blocks to disk as needed so that servers do not have to take the time to do these writes. Without the use of the -directio parameter, the apw write() calls return when the data has been copied to the operating system buffer, consequently less process time is taken. 

The additional time it takes an APW to do a database write when the -directio parameter is used happens because the write, rather than simply updating the OS filesystem cache, also pushes the data out to the disk sub-system. This increases what is called the I/O service time for each individual write rather significantly.

It is this increased time that makes it very critical to have enough APWs in use, and it is what makes buffers flushed at checkpoint so costly. Too few a number of APWs results in buffers flushed at checkpoints (more expensive when -directio is in use).

In extreme cases, -directio can require as many as 24 to 48 APWs, although you can expect no more than 8 for most production systems.
Workaround
Notes
Keyword Phrase
Last Modified Date11/20/2020 7:38 AM

Powered by