Junior — Middle
How does a running process differ from a zombie process in an operating system?
sobes.tech AI
Answer from AI
Orphan process — a process whose parent has finished before it. In Unix-like systems, such processes automatically become children of the init process (PID 1), which is then responsible for their proper termination.
Zombie process — a process that has completed execution but its parent has not yet called the wait() system call to retrieve its exit status. As a result, the process remains in the process table as "dead" (zombie), occupying an entry but not consuming CPU or memory resources.
Key difference:
- Orphan process is still active but has lost its parent.
- Zombie process has finished, but its parent has not processed its exit status, so its record remains in the system.