In: Computer Science
List the 4 reasons for process termination.
process termination is a technique in which a process is terminated and release the CPU after completing the execution.
main reasons for process termination:
1.Normal completion:complete all tasks and releases the CPU.
2.Protection Error:Process want to use a resource that is not allowed to use by the process.
for example:if a process wants to write on a file that is read only file.
3.I/O Failure:when a process attempts to use an I/O device and I/O device is not working fine at the moment.
For Example:a process that wants to print file on the printer, but the printer is defective.
4.Parent Request:if a process requests for terminating the child process then,child process should be terminated.
5.Parent Termination:when the parent is not in CPU,child process cannot exist in CPU.so when a parent is terminated,child process also needs to be terminated.
6.Arithmetic Error:There is an instruction of a process that invalid instruction,the process need to be terminated.
For Example:if a process wants to divide a number by ZERO.
7.Memory Requirement:a process require more memory to execute but the system fails to provide enough memory to the process for its execution,then the process needs to be terminated.