Add a description of the special kernel thread "ioflush" to the "special

processes" section, per PR 10912. While we're here, clean up nroff nits,
like spaces at the ends of lines.
This commit is contained in:
fair 2001-03-13 03:24:13 +00:00
parent 0dff585654
commit 4ca39aa709
1 changed files with 84 additions and 68 deletions

View File

@ -1,4 +1,4 @@
.\" $NetBSD: intro.2,v 1.22 2000/03/14 19:14:29 kleink Exp $
.\" $NetBSD: intro.2,v 1.23 2001/03/13 03:24:13 fair Exp $
.\"
.\" Copyright (c) 1980, 1983, 1986, 1991, 1993
.\" The Regents of the University of California. All rights reserved.
@ -84,7 +84,7 @@ An attempt was made to perform an operation limited to processes
with appropriate privileges or to the owner of a file or other
resources.
.It Er 2 ENOENT Em "No such file or directory" .
A component of a specified pathname did not exist, or the
A component of a specified pathname did not exist, or the
pathname was an empty string.
.It Er 3 ESRCH Em "No such process" .
No process could be found corresponding to that specified by the given
@ -95,7 +95,8 @@ An asynchronous signal (such as
or
.Dv SIGQUIT )
was caught by the process during the execution of an interruptible
function. If the signal handler performs a normal return, the
function.
If the signal handler performs a normal return, the
interrupted function call will seem to have returned the error condition.
.It Er 5 EIO Em "Input/output error" .
Some physical input or output error occurred.
@ -181,8 +182,8 @@ not a directory, when a directory was expected.
.It Er 21 EISDIR Em "Is a directory" .
An attempt was made to open a directory with write mode specified.
.It Er 22 EINVAL Em "Invalid argument" .
Some invalid argument was supplied. (For example,
specifying an undefined signal to a
Some invalid argument was supplied.
(For example, specifying an undefined signal to a
.Xr signal 3
or
.Xr kill 2
@ -211,11 +212,12 @@ while the pure procedure file was being executed an
.Xr open 2
call requested write access.
.It Er 27 EFBIG Em "File too large" .
The size of a file exceeded the maximum. (The system-wide maximum file size is
The size of a file exceeded the maximum.
(The system-wide maximum file size is
.if t 2\u\s-263\s+2\d
.if n 2**63
bytes. Each file system may impose a lower limit for files contained within
it.)
bytes.
Each file system may impose a lower limit for files contained within it).
.It Er 28 ENOSPC Em "Device out of space" .
A
.Xr write 2
@ -235,9 +237,9 @@ An attempt was made to modify a file or directory
was made
on a file system that was read-only at the time.
.It Er 31 EMLINK Em "Too many links" .
The number of hard links to a single file has exceeded the maximum. (The
system-wide maximum number of hard links is 32767. Each file system may
impose a lower limit for files contained within it.)
The number of hard links to a single file has exceeded the maximum.
(The system-wide maximum number of hard links is 32767.
Each file system may impose a lower limit for files contained within it).
.It Er 32 EPIPE Em "Broken pipe" .
A write on a pipe, socket or
.Tn FIFO
@ -270,7 +272,8 @@ A message sent on a socket was larger than the internal message buffer
or some other network limit.
.It Er 41 EPROTOTYPE Em "Protocol wrong type for socket" .
A protocol was specified that does not support the semantics of the
socket type requested. For example, you cannot use the
socket type requested.
For example, you cannot use the
.Tn ARPA
Internet
.Tn UDP
@ -319,9 +322,9 @@ The host you were connected to crashed and rebooted.
.It Er 53 ECONNABORTED Em "Software caused connection abort" .
A connection abort was caused internal to your host machine.
.It Er 54 ECONNRESET Em "Connection reset by peer" .
A connection was forcibly closed by a peer. This normally
results from a loss of the connection on the remote socket
due to a timeout or a reboot.
A connection was forcibly closed by a peer.
This normally results from a loss of the connection on the remote
socket due to a timeout or a reboot.
.It Er 55 ENOBUFS Em "\&No buffer space available" .
An operation on a socket or pipe was not performed because
the system lacked sufficient buffer space or because a queue was full.
@ -350,11 +353,12 @@ A
or
.Xr send 2
request failed because the connected party did not
properly respond after a period of time. (The timeout
period is dependent on the communication protocol.)
properly respond after a period of time.
(The timeout period is dependent on the communication protocol).
.It Er 61 ECONNREFUSED Em "Connection refused" .
No connection could be made because the target machine actively
refused it. This usually results from trying to connect
refused it.
This usually results from trying to connect
to a service that is inactive on the foreign host.
.It Er 62 ELOOP Em "Too many levels of symbolic links" .
A path name lookup involved more than 8 symbolic links.
@ -379,7 +383,7 @@ was supplied to a remove directory or rename call.
.It Er 68 EUSERS Em "Too many users" .
The quota system ran out of table entries.
.It Er 69 EDQUOT Em "Disc quota exceeded" .
A
A
.Xr write 2
to an ordinary file, the creation of a
directory or symbolic link, or the creation of a directory
@ -391,11 +395,10 @@ was exhausted.
An attempt was made to access an open file (on an
.Tn NFS
filesystem)
which is now unavailable as referenced by the file descriptor.
which is now unavailable as referenced by the file descriptor.
This may indicate the file was deleted on the
.Tn NFS
server or some
other catastrophic event occurred.
.Tn NFS
server or some other catastrophic event occurred.
.It Er 72 EBADRPC Em "RPC struct is bad" .
Exchange of
.Tn RPC
@ -408,7 +411,7 @@ the local version.
.It Er 74 EPROGUNAVAIL Em "RPC prog. not avail" .
The requested program is not registered on the remote host.
.It Er 75 EPROGMISMATCH Em "Program version wrong" .
The requested version of the program is not available
The requested version of the program is not available
on the remote host
.Pq Tn RPC .
.It Er 76 EPROCUNAVAIL Em "Bad procedure for program" .
@ -417,10 +420,10 @@ An
call was attempted for a procedure which doesn't exist
in the remote program.
.It Er 77 ENOLCK Em "No locks available" .
A system-imposed limit on the number of simultaneous file
A system-imposed limit on the number of simultaneous file
locks was reached.
.It Er 78 ENOSYS Em "Function not implemented" .
Attempted a system call that is not available on this
Attempted a system call that is not available on this
system.
.It Er 79 EFTYPE Em "Inappropriate file type or format" .
Attempted a file operation on a file of a type for which it was invalid.
@ -447,7 +450,8 @@ A wide character/multibyte character encoding error occured.
.Bl -tag -width Ds
.It Process ID .
Each active process in the system is uniquely identified by a non-negative
integer called a process ID. The range of this ID is from 0 to 30000.
integer called a process ID.
The range of this ID is from 0 to 30000.
.It Parent process ID
A new process is created by a currently active process; (see
.Xr fork 2 ) .
@ -457,9 +461,9 @@ the parent process ID of each child is set to the ID of a system process,
.Xr init 8 .
.It Process Group
Each active process is a member of a process group that is identified by
a non-negative integer called the process group ID. This is the process
ID of the group leader. This grouping permits the signaling of related
processes (see
a non-negative integer called the process group ID.
This is the process ID of the group leader.
This grouping permits the signaling of related processes (see
.Xr termios 4 )
and the job control mechanisms of
.Xr csh 1 .
@ -511,11 +515,11 @@ The process group of a session leader is orphaned by definition.
Each user on the system is identified by a positive integer
termed the real user ID.
.Pp
Each user is also a member of one or more groups.
Each user is also a member of one or more groups.
One of these groups is distinguished from others and
used in implementing accounting facilities. The positive
integer corresponding to this distinguished group is termed
the real group ID.
used in implementing accounting facilities.
The positive integer corresponding to this distinguished group is
termed the real group ID.
.Pp
All processes have a real user ID and real group ID.
These are initialized from the equivalent attributes
@ -530,17 +534,18 @@ group IDs, and it is unspecified whether the effective group ID is
a member of the list.)
.Pp
The effective user ID and effective group ID are initially the
process's real user ID and real group ID respectively. Either
may be modified through execution of a set-user-ID or set-group-ID
file (possibly by one its ancestors) (see
process's real user ID and real group ID respectively.
Either may be modified through execution of a set-user-ID or
set-group-ID file (possibly by one its ancestors) (see
.Xr execve 2 ) .
By convention, the effective group ID (the first member of the group access
list) is duplicated, so that the execution of a set-group-ID program
does not result in the loss of the original (real) group ID.
.Pp
The group access list is a set of group IDs
used only in determining resource accessibility. Access checks
are performed as described below in ``File Access Permissions''.
used only in determining resource accessibility.
Access checks are performed as described below in
.Qq File Access Permissions .
.It "Saved Set User ID and Saved Set Group ID"
When a process executes a new file, the effective user ID is set
to the owner of the file if the file is set-user-ID, and the effective
@ -559,13 +564,21 @@ A process is recognized as a
.Em super-user
process and is granted special privileges if its effective user ID is 0.
.It Special Processes
The processes with process IDs of 0, 1, 2 and 3 are special.
Process 0 is the scheduler. Process 1 is the initialization process
The processes with process IDs of 0, 1, 2, 3, and 4 are special.
Process 0 is the scheduler.
Process 1 is the initialization process
.Xr init 8 ,
and is the ancestor of every other process in the system.
and is the ancestor (parent) of every other process in the system.
It is used to control the process structure.
Process 2 is the paging daemon. Process 3 is the reaper, which handles
deallocating resources for exiting processes.
Process 2 is the paging daemon.
Process 3 is the
.Sy reaper ,
which handles deallocating resources for exiting processes.
Process 4 is
.Sy ioflush ,
which replaces the old
.Sy update
program that periodically flushes the disk buffer cache.
.It Descriptor
An integer assigned by the system when a file is referenced
by
@ -592,8 +605,8 @@ excluding 0 (NUL) and the
.Tn ASCII
code for
.Ql \&/
(slash). (The parity bit,
bit 7, must be 0.)
(slash).
(The parity bit, bit 7, must be 0).
.Pp
Note that it is generally unwise to use
.Ql \&* ,
@ -620,13 +633,13 @@ If a path name begins with a slash, the path search begins at the
.Em root
directory.
Otherwise, the search begins from the current working directory.
A slash by itself names the root directory. An empty
pathname refers to the current directory.
A slash by itself names the root directory.
An empty pathname refers to the current directory.
.It Directory
A directory is a special type of file that contains entries
that are references to other files.
Directory entries are called links. By convention, a directory
contains at least two links,
Directory entries are called links.
By convention, a directory contains at least two links,
.Ql \&.
and
.Ql \&.. ,
@ -634,40 +647,42 @@ referred to as
.Em dot
and
.Em dot-dot
respectively. Dot refers to the directory itself and
dot-dot refers to its parent directory.
respectively.
Dot refers to the directory itself and dot-dot refers to its parent directory.
.It "Root Directory and Current Working Directory"
Each process has associated with it a concept of a root directory
and a current working directory for the purpose of resolving path
name searches. A process's root directory need not be the root
name searches.
A process's root directory need not be the root
directory of the root file system.
.It File Access Permissions
Every file in the file system has a set of access permissions.
These permissions are used in determining whether a process
may perform a requested operation on the file (such as opening
a file for writing). Access permissions are established at the
time a file is created. They may be changed at some later time
through the
a file for writing).
Access permissions are established at the time a file is created.
They may be changed at some later time through the
.Xr chmod 2
call.
call.
.Pp
File access is broken down according to whether a file may be: read,
written, or executed. Directory files use the execute
permission to control if the directory may be searched.
written, or executed.
Directory files use the execute permission to control if the
directory may be searched.
.Pp
File access permissions are interpreted by the system as
they apply to three different classes of users: the owner
of the file, those users in the file's group, anyone else.
Every file has an independent set of access permissions for
each of these classes. When an access check is made, the system
decides if permission should be granted by checking the access
information applicable to the caller.
each of these classes.
When an access check is made, the system decides if permission should be
granted by checking the access information applicable to the caller.
.Pp
Read, write, and execute/search permissions on
a file are granted to a process if:
.Pp
The process's effective user ID is that of the super-user. (Note:
even the super-user cannot execute a non-executable file.)
The process's effective user ID is that of the super-user.
(Note: even the super-user cannot execute a non-executable file).
.Pp
The process's effective user ID matches the user ID of the owner
of the file and the owner permissions allow the access.
@ -701,14 +716,15 @@ for more information about the types available and
their properties.
.Pp
Each instance of the system supports some number of sets of
communications protocols. Each protocol set supports addresses
of a certain format. An Address Family is the set of addresses
for a specific group of protocols. Each socket has an address
communications protocols.
Each protocol set supports addresses of a certain format.
An Address Family is the set of addresses for a specific group of protocols.
Each socket has an address
chosen from the address family in which the socket was created.
.El
.Sh SEE ALSO
.Xr intro 3 ,
.Xr perror 3
.Xr perror 3
.Sh HISTORY
An
.Nm intro