Welcome! Log In Create A New Profile

Advanced

Re: aio info

May 05, 2011 03:14AM
On Thu, May 05, 2011 at 05:05:37AM +0000, Richard Kearsley wrote:
> Hi
> A lot of talk about AIO recently - I actually didn't know it existed before, so I am trying it on freebsd8
>
> # sysctl -a | grep aio
> kern.features.aio: 1
> vfs.aio.max_buf_aio: 16
> vfs.aio.max_aio_queue_per_proc: 256
> vfs.aio.max_aio_per_proc: 32
> vfs.aio.unloadable: 0
> vfs.aio.aiod_lifetime: 30000
> vfs.aio.aiod_timeout: 10000
> vfs.aio.num_buf_aio: 0
> vfs.aio.num_queue_count: 0
> vfs.aio.max_aio_queue: 1024
> vfs.aio.target_aio_procs: 4
> vfs.aio.num_aio_procs: 4
> vfs.aio.max_aio_procs: 32
>
> Could anyone comment what these mean and how to go about tweaking for best performance (should any be increased?)

$ sysctl -d vfs.aio
vfs.aio: Async IO management
vfs.aio.max_buf_aio: Maximum buf aio requests per process (stored in the process)
vfs.aio.max_aio_queue_per_proc: Maximum queued aio requests per process (stored in the process)
vfs.aio.max_aio_per_proc: Maximum active aio requests per process (stored in the process)
vfs.aio.unloadable: Allow unload of aio (not recommended)
vfs.aio.aiod_lifetime: Maximum lifetime for idle aiod
vfs.aio.aiod_timeout: Timeout value for synchronous aio operations
vfs.aio.num_buf_aio: Number of aio requests presently handled by the buf subsystem
vfs.aio.num_queue_count: Number of queued aio requests
vfs.aio.max_aio_queue: Maximum number of aio requests to queue, globally
vfs.aio.target_aio_procs: Preferred number of ready kernel threads for async IO
vfs.aio.num_aio_procs: Number of presently active kernel threads for async IO
vfs.aio.max_aio_procs: Maximum number of kernel threads to use for handling async IO

There are two types AIO operations inside FreeBSD kernel - raw file
AIO (buf aio) and usual file AIO that uses in-kernel threads/processes.
nginx uses only usual file AIO. Relevant sysctls are:

vfs.aio.max_aio_queue: 1024
vfs.aio.max_aio_queue_per_proc: 256
vfs.aio.max_aio_per_proc: 32
vfs.aio.num_queue_count: 0

vfs.aio.max_aio_procs: 32
vfs.aio.target_aio_procs: 4
vfs.aio.num_aio_procs: 4

vfs.aio.aiod_lifetime: 30000
vfs.aio.aiod_timeout: 10000

You may want to increase

vfs.aio.max_aio_procs
vfs.aio.max_aio_queue
vfs.aio.max_aio_queue_per_proc
vfs.aio.max_aio_per_proc

> Particularly.. vfs.aio.num_queue_count - does this monitor the amount of io waiting?

Yes.


--
Igor Sysoev

_______________________________________________
nginx mailing list
nginx@nginx.org
http://nginx.org/mailman/listinfo/nginx
Subject Author Posted

aio info

Richard Kearsley May 05, 2011 01:06AM

Re: aio info

Igor Sysoev May 05, 2011 03:14AM

RE: aio info

Richard Kearsley May 06, 2011 05:38AM

Re: aio info

Igor Sysoev May 06, 2011 06:52AM

RE: aio info

Richard Kearsley May 06, 2011 08:54AM

Re: aio info

Igor Sysoev May 06, 2011 09:02AM

RE: aio info

Richard Kearsley May 06, 2011 09:52AM

RE: aio info

Richard Kearsley May 09, 2011 05:34AM

Re: aio info

Maxim Dounin May 09, 2011 07:24AM



Sorry, only registered users may post in this forum.

Click here to login

Online Users

Guests: 185
Record Number of Users: 8 on April 13, 2023
Record Number of Guests: 421 on December 02, 2018
Powered by nginx      Powered by FreeBSD      PHP Powered      Powered by MariaDB      ipv6 ready