.L0 "Notation and Types" 4
.L1 "Kernel primitives" 4
.L2 "Processes and protection" 5
.L3 "Host identifiers" 5
.Nm sethostid 1 "set host identifier
.Nm gethostid 0 "get host identifier
.Nm sethostname 2 "set host name
.Nm gethostname 2 "get host name
.L3 "Process identifiers" 5
.Nm getpid 0 "get process identifier
.Nm getppid 0 "get parent process identifier
.L3 "Process creation and termination" 5
.Nm fork 0 "create a new process
.Nm vfork 0 "create a new process
.Nm exit 1 "terminate a process
.Nm wait4 4 "collect exit status of child
.Nm execve 3 "execute a new program
.L3 "User and group IDs" 6
.Nm getuid 0 "get real user identifier
.Nm geteuid 0 "get effective user identifier
.Nm getgid 0 "get real group identifier
.Nm getegid 0 "get effective group identifier
.Nm getgroups 2 "get access group set
.Nm setuid 1 "set real, effective, and saved user identifiers
.Nm setgid 1 "set real, effective, and saved group identifiers
.Nm setgroups 2 "set access group set
.Nm seteuid 1 "set effective user identifier
.Nm setegid 1 "set effective group identifier
.L3 "Sessions" 7
.Nm setsid 0 "create a new session
.Nm setlogin 1 "set login name
.Nm getlogin 0 "get login name
.L3 "Process groups" 7
.Nm getpgrp 0 "get process group
.Nm setpgid 2 "set process group
.L2 "Memory management" 8
.L3 "Text, data, and stack" 8
.Nm brk 1 "set data section size
.Nm sbrk 1 "change data section size
.L3 "Mapping pages" 8
.Nm getpagesize 0 "get system page size
.Nm mmap 6 "map files or devices into memory
.Nm msync 2 "synchronize a mapped region
.Nm munmap 2 "remove a mapping
.L3 "Page protection control" 10
.Nm mprotect 3 "control the protection of pages
.L3 "Giving and getting advice" 10
.Nm madvise 3 "give advise about use of memory
.Nm mincore 3 "get advise about use of memory
.Nm mlock 2 "lock physical pages in memory
.Nm munlock 2 "unlock physical pages in memory
.L3 "Synchronization primitives" 11
.Nm mset 2 "acquire and set a semaphore
.Nm mclear 2 "release a semaphore and awaken waiting processes
.Nm msleep 1 "wait for a semaphore
.Nm mwakeup 1 "awaken process(es) sleeping on a semaphore
.L2 "Signals" 11
.L3 "Overview" 11
.L3 "Signal types" 12
.L3 "Signal handlers" 12
.Nm sigaction 3 "setup software signal handler
.Nm sigreturn 1 "return from a signal
.L3 "Sending signals" 13
.Nm kill 2 "send signal to a process
.Nm killpg 2 "send signal to a process group
.L3 "Protecting critical sections" 14
.Nm sigprocmask 3 "manipulate current signal mask
.Nm sigsuspend 1 "atomically release blocked signals and wait for interrupt
.Nm sigpending 1 "get pending signals
.L3 "Signal stacks" 14
.Nm sigaltstack 2 "set and/or get signal stack context
.L2 "Timers" 14
.L3 "Real time" 14
.Nm settimeofday 2 "set date and time
.Nm gettimeofday 2 "get date and time
.Nm adjtime 2 "synchronization of the system clock
.L3 "Interval time" 15
.Nm setitimer 3 "set value of interval timer
.Nm getitimer 2 "get value of interval timer
.Nm profil 4 "control process profiling
.L2 "Descriptors" 16
.L3 "The reference table" 16
.Nm getdtablesize 0 "get descriptor table size
.L3 "Descriptor properties" 16
.L3 "Managing descriptor references" 17
.Nm dup 1 "duplicate an existing file descriptor
.Nm dup2 2 "duplicate an existing file descriptor
.Nm close 1 "delete a descriptor
.L3 "Multiplexing requests" 17
.Nm select 5 "synchronous I/O multiplexing
.Nm fcntl 3 "file control
.L2 "Resource controls" 18
.L3 "Process priorities" 18
.Nm getpriority 2 "get program scheduling priority
.Nm setpriority 3 "set program scheduling priority
.L3 "Resource utilization" 19
.Nm getrusage 2 "get information about resource utilization
.L3 "Resource limits" 19
.Nm getrlimit 2 "get maximum system resource consumption
.Nm setrlimit 2 "set maximum system resource consumption
.L2 "System operation support" 20
.L3 "Monitoring system operation" 20
.Nm sysctl 6 "get or set system information
.L3 "Bootstrap operations" 21
.Nm mount 4 "mount a filesystem
.Nm getfsstat 3 "get list of all mounted filesystems
.Nm swapon 1 "add a swap device for interleaved paging/swapping
.L3 "Shutdown operations" 21
.Nm unmount 2 "dismount a filesystem
.Nm sync 0 "force completion of pending disk writes (flush cache)
.Nm reboot 1 "reboot system or halt processor
.L3 "Accounting" 21
.Nm acct 1 "enable or disable process accounting
.L1 "System facilities" 22
.L2 "Generic operations" 22
.L3 "Read and write" 22
.Nm read 3 "read input
.Nm write 3 "write output
.Nm readv 3 "read gathered input
.Nm writev 3 "write scattered output
.L3 "Input/output control" 23
.Nm ioctl 3 "control device
.L3 "Non-blocking and asynchronous operations" 23
.L2 "Filesystem" 24
.L3 "Overview" 24
.L3 "Naming" 24
.Nm chdir 1 "change current working directory
.Nm fchdir 1 "change current working directory
.Nm chroot 1 "change root directory
.Nm statfs 2 "get file system statistics
.Nm fstatfs 2 "get file system statistics
.L3 "Creation and removal" 24
.L4 "Directory creation and removal" 25
.Nm mkdir 2 "make a directory file
.Nm rmdir 1 "remove a directory file
.Nm getdirentries 4 "get directory entries in a filesystem independent format
.L4 "File creation" 25
.Nm open 3 "open or create a file for reading or writing
.Nm umask 1 "set file creation mode mask
.L4 "Creating references to devices" 26
.Nm mknod 3 "make a special file node
.Nm mkfifo 2 "make a fifo file
.L4 "Links and renaming" 27
.Nm link 2 "make a hard file link
.Nm symlink 2 "make a symbolic link to a file
.Nm readlink 3 "read value of a symbolic link
.Nm rename 2 "change the name of a file
.L4 "File, device, and fifo removal" 27
.Nm unlink 1 "remove directory entry
.Nm revoke 1 "revoke file access
.L3 "Reading and modifying file attributes" 28
.Nm stat 2 "get file status
.Nm fstat 2 "get file status
.Nm lstat 2 "get file status
.Nm chown 3 "change owner and group of a file
.Nm fchown 3 "change owner and group of a file
.Nm chmod 2 "change mode of file
.Nm fchmod 2 "change mode of file
.Nm chflags 2 "set file flags
.Nm fchflags 2 "set file flags
.Nm utimes 2 "set file access and modification times
.L3 "Checking accessibility" 29
.Nm access 2 "check access permissions of a file or pathname
.Nm pathconf 2 "get configurable pathname variables
.Nm fpathconf 2 "get configurable pathname variables
.L3 "Extension and truncation" 29
.Nm lseek 3 "reposition read/write file offset
.Nm truncate 2 "truncate a file to a specified length
.Nm ftruncate 2 "truncate a file to a specified length
.Nm fsync 1 "synchronize in-core state of a file with that on disk
.L3 "Locking" 30
.Nm flock 2 "apply or remove an advisory lock on an open file
.L3 "Disk quotas" 30
.Nm quotactl 4 "manipulate filesystem quotas
.L3 "Remote filesystems" 31
.Nm nfssvc 2 "NFS services
.Nm getfh 2 "get file handle
.L3 "Other filesystems" 31
.L2 "Interprocess communications" 32
.L3 "Interprocess communication primitives" 32
.L4 "Communication domains" 32
.L4 "Socket types and protocols" 32
.L4 "Socket creation, naming and service establishment" 33
.Nm socket 3 "create an endpoint for communication
.Nm bind 3 "bind a name to a socket
.Nm getsockname 3 "get socket name
.Nm getpeername 3 "get name of connected peer
.L4 "Accepting connections" 33
.Nm listen 2 "listen for connections on a socket
.Nm accept 3 "accept a connection on a socket
.L4 "Making connections" 34
.Nm connect 3 "initiate a connection on a socket
.Nm socketpair 4 "create a pair of connected sockets
.Nm pipe 1 "create descriptor pair for interprocess communication
.L4 "Sending and receiving data" 34
.Nm sendto 6 "send a message from a socket
.Nm send 4 "send a message from a socket
.Nm recvfrom 6 "receive a message from a socket
.Nm recv 4 "receive a message from a socket
.L4 "Scatter/gather and exchanging access rights" 35
.Nm sendmsg 3 "send a message from a socket
.Nm recvmsg 3 "receive a message from a socket
.L4 "Using read and write with sockets" 36
.L4 "Shutting down halves of full-duplex connections" 36
.Nm shutdown 2 "shut down part of a full-duplex connection
.L4 "Socket and protocol options" 36
.Nm getsockopt 5 "get options on socket
.Nm setsockopt 5 "set options on socket
.L3 "PF_LOCAL domain" 36
.L4 "Types of sockets" 36
.L4 "Naming" 36
.L4 "Access rights transmission" 37
.L3 "INTERNET domain" 37
.L4 "Socket types and protocols" 37
.L4 "Socket naming" 37
.L4 "Access rights transmission" 37
.L4 "Raw access" 37
.L2 "Terminals and Devices" 37
.L3 "Terminals" 37
.L4 "Terminal input" 38
.L4 "Terminal output" 38
.L3 "Structured devices" 38
.L3 "Unstructured devices" 39
.L2 "Process debugging" 39
.L3 "Traditional debugging" 39
.Nm ptrace 4 "process trace
.L3 "Kernel tracing" 39
.Nm ktrace 4 "process tracing
.L1 "Summary of facilities" 40
