The basic unit of execution in a Unix system is a process. A process is an instance of a running program. Each process has its own memory space, its own set of open files, and its own set of environment variables. Processes are created using the fork() system call. The fork() system call creates a new process that is an exact copy of the parent process. The new process has its own memory space, but it shares the parent process's open files and environment variables. Processes can be terminated using the exit() system call. The exit() system call causes the process to terminate and return a... Show more The basic unit of execution in a Unix system is a process. A process is an instance of a running program. Each process has its own memory space, its own set of open files, and its own set of environment variables. Processes are created using the fork() system call. The fork() system call creates a new process that is an exact copy of the parent process. The new process has its own memory space, but it shares the parent process's open files and environment variables. Processes can be terminated using the exit() system call. The exit() system call causes the process to terminate and return a status code to its parent process. Processes can also be terminated by signals. Signals are software interrupts that can be sent to processes by the kernel or by other processes. Signals can cause a process to terminate, stop, or continue execution. The wait() system call allows a parent process to wait for its child process to terminate. The wait() system call returns the status code of the child process. The following are some of the most important Unix system calls for process control: fork() - creates a new process exec() - loads a new program into a process exit() - terminates a process wait() - waits for a child process to terminate kill() - sends a signal to a process sleep() - causes a process to sleep for a period of time Show less
The basic unit of execution in a Unix system is a process. A process is an instance of a running program. Each process has its own memory space, its own set of open files, and its own set of environment variables. Processes are created using the fork() system call. The fork() system call creates a new process that is an exact copy of the parent process. The new process has its own memory space, but it shares the parent process's open files and environment variables. Processes can be terminated using the exit() system call. The exit() system call causes the process to terminate and return a status code to its parent process. Processes can also be terminated by signals. Signals are software interrupts that can be sent to processes by the kernel or by other processes. Signals can cause a process to terminate, stop, or continue execution.
The wait() system call allows a parent process to wait for its child process to terminate. The wait() system call returns the status code of the child process.
The following are some of the most important Unix system calls for process control: fork() - creates a new process exec() - loads a new program into a process exit() - terminates a process wait() - waits for a child process to terminate kill() - sends a signal to a process sleep() - causes a process to sleep for a period of time
Join 4M+ learners. Unlock unlimited quizzes, wrong-answer tracking, flashcards + reminders, study guides, and 1-on-1 challenges.