aio(4) 맨 페이지 - 윈디하나의 솔라나라

개요

섹션
맨 페이지 이름
검색(S)

aio(4)

The  facility  provides system calls for asynchronous I/O.  Asyn‐
chronous I/O operations are not completed  synchronously  by  the
calling  thread.   Instead, the calling thread invokes one system
call to request an asynchronous I/O operation.  The status  of  a
completed  request is retrieved later via a separate system call.
Asynchronous I/O operations on some  file  descriptor  types  may
block an AIO daemon indefinitely resulting in process and/or sys‐
tem hangs.  Operations on these file descriptor types are consid‐
ered and disabled by default.  They can be enabled by setting the
sysctl  node to a non-zero value.  Asynchronous I/O operations on
sockets, raw disk devices, and regular files on local filesystems
do not block indefinitely and are always enabled.   The  facility
uses kernel processes (also known as AIO daemons) to service most
asynchronous  I/O  requests.   These  processes  are grouped into
pools containing a variable number of processes.  Each pool  will
add  or remove processes to the pool based on load.  Pools can be
configured by sysctl nodes that define the  minimum  and  maximum
number of processes as well as the amount of time an idle process
will  wait  before  exiting.   One pool of AIO daemons is used to
service asynchronous I/O requests for sockets.   These  processes
are named The following sysctl nodes are used with this pool: The
current  number  of processes in the pool.  The minimum number of
processes that should be present in the pool.  The maximum number
of processes permitted in the pool.  The amount of time a process
is permitted to idle in clock ticks.  If a process  is  idle  for
this amount of time and there are more processes in the pool than
the  target minimum, the process will exit.  A second pool of AIO
daemons is used to service all other  asynchronous  I/O  requests
except  for I/O requests to raw disks.  These processes are named
The following sysctl nodes are used with this pool:  The  current
number of processes in the pool.  The minimum number of processes
that  should  be  present  in  the  pool.   The maximum number of
processes permitted in the pool.  The amount of time a process is
permitted to idle in clock ticks.  If a process is idle for  this
amount  of time and there are more processes in the pool than the
target minimum, the process will exit.  Asynchronous I/O requests
for raw disks are queued directly to the disk device layer  after
temporarily  wiring  the  user pages associated with the request.
These requests are not serviced by any of the AIO  daemon  pools.
Several limits on the number of asynchronous I/O requests are im‐
posed both system-wide and per-process.  These limits are config‐
ured  via  the  following  sysctls:  The maximum number of queued
asynchronous I/O requests for raw disks permitted  for  a  single
process.  Asynchronous I/O requests that have completed but whose
status has not been retrieved via or are not counted against this
limit.   The  number  of queued asynchronous I/O requests for raw
disks system-wide.  The maximum number of  asynchronous  I/O  re‐
quests  for a single process serviced concurrently by the default
AIO daemon pool.  The maximum number of outstanding  asynchronous
I/O  requests  permitted for a single process.  This includes re‐
quests that have not been serviced, requests currently being ser‐
viced, and requests that have completed but whose status has  not
been  retrieved via or The number of outstanding asynchronous I/O
requests system-wide.  The maximum number  of  outstanding  asyn‐
chronous  I/O  requests  permitted system-wide.  Asynchronous I/O
control buffers should be zeroed before  initializing  individual
fields.   This ensures all fields are initialized.  All asynchro‐
nous I/O control buffers contain a structure in the  field  which
can  be used to request notification when an operation completes.
For notifications, the s field should contain the  descriptor  of
the  kqueue  that  the event should be attached to, its field may
contain field should be set to The posted  kevent  will  contain:
value  stored  in  For and notifications, the information for the
queued signal will include in the field and the value  stored  in
in  the  field.  For notifications, the value stored in is passed
to the as described in The facility appeared as a  kernel  option
in The kernel module appeared in The facility was integrated into
all kernels in
































































맨 페이지 내용의 저작권은 맨 페이지 작성자에게 있습니다.
RSS ATOM XHTML 5 CSS3