Zombie Processes in Linux

Source: Internet
Author: User
Tags signal handler

1. What is a zombie process?

A zombie process is a child process that ends before the parent process, but the parent process does not reclaim the child process and frees the resources that the child process occupies. The zombie process also occupies a slot in the process table, but the process table has limited capacity, and the defunct process not only consumes system resources, but also affects system performance, which can cause the system to fail if the number is large. Here is an image of the explanation: the process immediately after exiting into a zombie, and then wait for the parent process corpse, if the parent process is dead, that is, the process is an orphan, its parent process "Tuogu" the init process, that is, its adoptive father, will help it corpse. If the parent process here is not dead, it depends on what the parent process is doing. If the parent process is calling a wait or waitpid operation, the parent process is prepared to have the coffin paper money, and the process can be buried. or the parent process sets the SIGCHLD signal handler function and performs a wait or waitpid operation in the handler, no problem. But if the parent process is too busy, without any idea of a corpse, the process will have to remain in zombie state until the parent process remembers to wait or waitpid the corpse, or the parent process dies.

2. How to view the zombie process?



2. How to kill the zombie process?

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.