NAME
intro - Describes error conditions
DESCRIPTION
This reference page describes the error conditions under
which the invoked function will or may fail to complete suc-
cessfully, and the value of errno associated with each.
The following list summarizes and describes the error codes
(errnos) returned by functions in alphabetical order.
Some error codes represent more than one type of error. For
example, [E2BIG] can indicate that the specified argument
size has exceeded the system limit of ARG_MAX, or that the
specified number of sembuf structures has exceeded a prede-
fined limit.
[E2BIG]
Indicates that the specified argument list exceeds the
system limit of ARG_MAX bytes, or the number of bytes in
the message exceeds the predefined limit.
The value of errno is 7.
[EACCES]
Indicates that the requested operation did not have the
proper access permissions. This error may also indicate
one or more of the following:
o The named file is not an ordinary file (acct()).
o The operation would cause the parent directory or
process' information level to float such that it
would no longer be dominated by the directory or
process' sensitivity level.
o The requested file is not available for read or
write access.
o The process is attempting to mount on a multilevel
child directory.
o The value of the process ID argument matches the
process ID of a child process of the calling pro-
cess and the child process has successfully exe-
cuted one of the exec functions (setpgid()).
o The function is trying to manipulate two files on
two different file systems (setquota()).
The value of errno is 13.
[EADDRINUSE]
Indicates that the specified address is already in use.
The value of errno is 48.
[EADDRNOTAVAIL]
Indicates that the specified address is not available
from the local machine.
The value of errno is 49.
[EAFNOSUPPORT]
Indicates that the addresses in the specified address
family are not supported by the protocol family.
The value of errno is 47.
[EAGAIN]
Indicates that the requested resource, such as a lock or
a process, is temporarily unavailable. This error may
also indicate one or both of the following:
o If the O_NONBLOCK flag is set for the requested
function, the process would be delayed in a read or
write operation.
o The specified time has elapsed
(pthread_cond_timedwait()).
The value of errno is 35.
[EBADF]
Indicates that a socket or file descriptor parameter is
invalid.
The value of errno is 9.
[EBUSY]
Indicates that the requested element is currently una-
vailable, or the associated system limit was exceeded.
The value of errno is 16.
[ECHILD]
Indicates either that the child process does not exist,
or that the requested child process information is una-
vailable.
The value of errno is 10.
[ECONNABORTED]
Indicates that the software caused a connection abort
because there is no space on the socket's queue and the
socket cannot receive further connections.
The value of errno is 53.
[ECONNREFUSED]
Indicates that the connection request was refused.
The value of errno is 61.
[EDEADLK]
Indicates either a probable deadlock condition, or that
the requested lock is owned by someone else.
The value of errno is 11.
[EDOM]
Indicates that x and/or y are either Not a Number (NaN),
or that they are in some other way unacceptable (for
example, exceed system limits).
The value of errno is 33.
[EDQUOT]
Indicates that the file system of the requested direc-
tory has exceeded the user's quota of disk blocks.
The value of errno is 69.
[EEXIST]
Indicates that the request element (for example, file,
semaphore, etc.) already exists.
The value of errno is 17.
[EFAULT]
Indicates that the requested address is in some way
invalid, for example, out of bounds.
The value of errno is 14.
[EFBIG]
Indicates either that the file size exceeds the process'
file size limit, or that the requested semphore number
is invalid (0 or greater than or equal to the specified
number of semaphores).
The value of errno is 27.
[EFTYPE]
Indicates that a file's type or format is inappropriate.
The value of errno is 79.
[EIDRM]
Indicates that the requested semaphore or message queue
ID has been removed from the system.
The value of errno is 81.
[EINTR]
Indicates that an interruptible function's process was
interrupted by a signal, which it caught.
The value of errno is 4.
[EINVAL]
Indicates that an invalid argument was passed to the
function (such as, the requested argument does not exist
or is out of bounds or is not a regular file, or that
the result would be invalid). This error may also indi-
cate one or more of the following:
o The requested socket is not accepting connections
(accept()) or is already bound (bind()).
o The specified super block had a bad magic number or
out of range block size (mount()).
o The requested parameter is a lock/unlock parameter,
but the element to be locked is already
locked/unlocked (plock()).
o The kernel has not been compiled with the QUOTA
option (quota()).
o An attempt was made to to ignore or supply a
handler for the SIGKILL, SIGSTOP, and SIGCONT sig-
nals (sigaction()).
o The requested device was not configured as a swap
device or does not allow paging (swapon()).
o The requested device is not mounted or local
(mount()).
The value of errno is 22.
[EIO]
Indicates a read or write physical I/O error. These
errors do not always occur with the associated function,
but can occur with the subsequent function. This error
may also indicate that the requested parameter does not
have an appropriate value, or is invalid (ptrace()).
The value of errno is 5.
[EISCONN]
Indicates that the socket is already connected.
The value of errno is 56.
[EISDIR]
Indicates either that the request was for a write access
to a file but the specified filename was actually a
directory, or that the function was trying to rename a
directory as a file.
The value of errno is 21.
[ELOOP]
Indicates that too many links were encountered in
translating a pathname.
The value of errno is 62.
[EMFILE]
Indicates one or more of the following errors:
o Too many file descriptors are open (exceeding
OPEN_MAX).
o No space remains in the mount table.
o The attempt to attach a shared memory region
exceeded the maximum number of attached regions
allowed for any one process.
The value of errno is 24.
[EMLINK]
Indicates that the number of links would exceed
LINK_MAX.
The value of errno is 31.
[EMSGSIZE]
Indicates that the message is too large to be sent all
at once, as the socket requires.
The value of errno is 40.
[ENAMETOOLONG]
Indicates that the pathname argument exceeds PATH_MAX
(currently 1024) or a pathname component exceeds
NAME_MAX (255).
The value of errno is 63.
[ENETUNREACH]
Indicates that no route to the network or host exists.
The value of errno is 51.
[ENFILE]
Indicates either that the system file table is full, or
that there are too many files currently open in the sys-
tem.
The value of errno is 23.
[ENOBUFS]
Indicates insufficient resources, such as buffers, to
complete the call.
The value of errno is 55.
[ENODEV]
Indicates one or more of the following errors:
o The file descriptor refers to an object that cannot
be mapped.
o The requested block special device file does not
exist.
o A file system is unmounted.
The value of errno is 19.
[ENOENT]
Indicates one or more of the following errors:
o The specified file pathname or directory pathname
does not exist or points to an empty string.
o The O_CREAT flag is set and the named file or path
prefix does not exist (open()).
o A message queue identifier does not exist for a
message key identifier and the IPC_CREAT flag is
not set for the function (msgget()).
o A semaphore ID does not exist for a semaphore key
identifier and the IPC_CREAT flag is not set for
the function (semget()).
o A shared memory region ID does not exist for a
shared memory region key identifier and the
IPC_CREAT flag is set for the function (shmeget()).
The value of errno is 2.
[ENOEXEC]
Indicates that the specified file has appropriate access
permissions but has an improper format, such as an
unrecognizable object file format.
The value of errno is 8.
[ENOLCK]
Indicates that lock table is full because too many
regions are already locked, or satisfying a lock/unlock
request would result in the number of locked regions in
the system exceeding a system-imposed limit.
The value of errno is 77.
[ENOMEM]
Indicates that insufficient memory is available for the
requested function. This error may indicate one or more
of the following errors:
o Mapped region attribute was set and part of the
specified address range is already allocated
(mmap()).
o The specified range is invalid for a process'
address space or the range specifies one or more
unmapped pages (msync()).
o A new semaphore could not be created (msem_init()).
The value of errno is 12.
[ENOMSG]
Indicates that a message of the requested type does not
exist and the IPC_NOWAIT flag is set.
The value of errno is 80.
[ENOPKG]
Indicates that the specified package was not found.
The value of errno is 92.
[ENOPROTOOPT]
Indicates that the requested socket option is unknown
and the protocol is unavailable.
The value of errno is 42.
[ENOSPC]
Indicates one or more of the following errors:
o Not enough space to extend the file system or dev-
ice for file and/or directory writes.
o The advise() function tried to reserve resources
that were not available to be reserved.
o The system-imposed limit of the maximum number of
allowed message queue identifiers has been exceeded
(msgget()).
o An attempt to create a semaphore ID exceeded the
system-wide limit on the semaphore table
(semget()).
o An attempt to create a new shared memory region ID
exceeded the system-wide limit of maximum IDs
(shmget()).
o The system-defined limit on the number of processes
using SEM_UNDO was exceeded (semop()).
The value of errno is 28.
[ENOSYM]
Indicates that the specified package does not contain
the named symbol.
The value of errno is 93.
[ENOTBLK]
Indicates that the specified parameter is not or does
not point to a block device.
The value of errno is 15.
[ENOTCONN]
Indicates that the socket is not connected.
The value of errno is 57.
[ENOTDIR]
Indicates that a component of the path parameter is not
a directory, or an operation is being performed from a
directory to a nonexistent directory.
The value of errno is 20.
[ENOTSOCK]
Indicates that the specified socket parameter refers to
a file, not a socket.
The value of errno is 38.
[ENOTTY]
Indicates one or more of the following errors:
o The file descriptor's file is not a terminal.
o The calling process does not have a controlling
terminal.
o The controlling terminal is no longer associated
with the calling process session (tcsetpgrp()).
o The specified open descriptor is not associated
with a character special device or the specified
request does not apply to the kind of object that
the specified open descriptor references (ioctl()).
The value of errno is 25.
[ENXIO]
Indicates one or more of the following errors:
o The specified address, major device number, or
channel is out of valid range.
o No more channels are available (open()).
o The named file is a character or block special file
and the associated device does not exist (open()).
o The O_NONBLOCK flag is set, the named file is FIFO,
O_WRONLY is set, and no process has the file open
for reading (open()).
The value of errno is 6.
[EOPNOTSUPP]
Indicates either that the socket does not support the
requested operation, or that the socket cannot accept
the connection.
The value of errno is 45.
[EPERM]
Indicates that the function attempted to perform an
operation for which it did not have appropriate
privileges (such as the privileges allowed by the secu-
rity options), or the caller was not the owner of the
requested element or superuser. This error may also
indicate one or both of the following:
o The calling process was not in the same session as
the target process (setpgid()).
o The calling process is already the process group
leader or the process group ID of a process other
than the calling process matches the process ID of
the calling process (setsid()).
The value of errno is 1.
[EPIPE]
Indicates that an attempt was made to write to a pipe or
FIFO that was not open for reading by any process.
The value of errno is 32.
[EPROTONOSUPPORT]
Indicates that either the socket or the protocol is not
supported.
The value of errno is 43.
[ERANGE]
Indicates one or more of the following errors:
o The result would exceed the system-defined limits
or cause an overflow (value too large) or an under-
flow (value too small).
o A specified parameter is greater than 0 (zero) but
smaller than the length of the pathname + 1
(getcwd()).
o The symbol value cannot be represented as an abso-
lute value.
o The magnitude of x is such that total or partial
loss of significance resulted.
The value of errno is 34.
[EROFS]
Indicates one or more of the following errors:
o The operation requested was to be performed on a
read-only file system.
o An attempt was made to activate a paging file on a
read-only file system.
o The named file resides on a read-only file system
and the file type requires write access.
The value of errno is 30.
[ESPIPE]
Indicates that an invalid seek operation was requested
for a pipe (FIFO), socket, or multiplexed special file.
The value of errno is 29.
[ESRCH]
Indicates one or more of the following errors:
o The requested process or child process ID is
invalid or not in use.
o No disk quota is found for the specified user.
o The specified thread ID does not refer to an exist-
ing thread.
The value of errno is 3.
[ESTALE]
Indicates that the specified process' root or current
directory is located in a virtual file system that has
been unmounted (stale NFS file handle).
The value of errno is 70.
[ETIMEDOUT]
Indicates that the requested attempt at a connection
timed out before a connection was established.
The value of errno is 60.
[ETXTBSY]
Indicates either that the requested file is currently
opened for writing by another process, or that a write
access is requested by a pure procedure (shared text)
file that is being executed.
The value of errno is 26.
[EUSERS]
Indicates that there are too many users, as evidenced by
a full quota table.
The value of errno is 68.
[EWOULDBLOCK]
Indicates one or more of the following errors:
o The socket is marked nonblocking and no connections
are waiting to be accepted.
o The socket is marked nonblocking and connection
cannot be immediately completed.
o The file is locked and the function is instructed
not to block when locking.
o The socket is marked as nonblocking and no space is
available for the specified function.
The value of errno is 35.
[EXDEV]
Indicates either that a hard link was attempted between
two file systems, or that a filename to be renamed by
rename() is on a different file system from the link to
which it is to be renamed.
The value of errno is 18.
Acknowledgement and Disclaimer