{"id":90445,"date":"2024-03-06T14:06:13","date_gmt":"2024-03-06T06:06:13","guid":{"rendered":"http:\/\/lrxjmw.cn\/?p=90445"},"modified":"2024-03-06T14:06:13","modified_gmt":"2024-03-06T06:06:13","slug":"zombie-linux","status":"publish","type":"post","link":"https:\/\/lrxjmw.cn\/zombie-linux.html","title":{"rendered":"\u5982\u4f55\u5904\u7406\u50f5\u5c38\u8fdb\u7a0b\uff1f"},"content":{"rendered":"\n\n\n
\u5bfc\u8bfb<\/td>\n\u5982\u679c\u4f60\u7ecf\u5e38\u4f7f\u7528 Linux\uff0c\u4f60\u5e94\u8be5\u9047\u5230\u8fd9\u4e2a\u672f\u8bed\u201c\u50f5\u5c38\u8fdb\u7a0b\u201d\u3002 \u90a3\u4e48\u4ec0\u4e48\u662f\u50f5\u5c38\u8fdb\u7a0b\uff1f \u5b83\u4eec\u662f\u600e\u4e48\u4ea7\u751f\u7684\uff1f \u5b83\u4eec\u662f\u5426\u5bf9\u7cfb\u7edf\u6709\u5bb3\uff1f \u6211\u8981\u600e\u6837\u6740\u6389\u8fd9\u4e9b\u8fdb\u7a0b\uff1f \u4e0b\u9762\u5c06\u4f1a\u56de\u7b54\u8fd9\u4e9b\u95ee\u9898\u3002<\/strong><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n

\"\"<\/p>\n

\u4ec0\u4e48\u662f\u50f5\u5c38\u8fdb\u7a0b\uff1f<\/strong><\/div>\n

\u6211\u4eec\u90fd\u77e5\u9053\u8fdb\u7a0b\u7684\u5de5\u4f5c\u539f\u7406\u3002\u6211\u4eec\u542f\u52a8\u4e00\u4e2a\u7a0b\u5e8f\uff0c\u5f00\u59cb\u6211\u4eec\u7684\u4efb\u52a1\uff0c\u7136\u540e\u7b49\u4efb\u52a1\u7ed3\u675f\u4e86\uff0c\u6211\u4eec\u5c31\u505c\u6b62\u8fd9\u4e2a\u8fdb\u7a0b\u3002 \u8fdb\u7a0b\u505c\u6b62\u540e\uff0c \u8be5\u8fdb\u7a0b\u5c31\u4f1a\u4ece\u8fdb\u7a0b\u8868\u4e2d\u79fb\u9664\u3002<\/p>\n

\u4f60\u53ef\u4ee5\u901a\u8fc7 System-Monitor<\/code> \u67e5\u770b\u5f53\u524d\u8fdb\u7a0b\u3002<\/p>\n

\u4f46\u662f\uff0c\u6709\u65f6\u5019\u6709\u4e9b\u7a0b\u5e8f\u5373\u4f7f\u6267\u884c\u5b8c\u4e86\u4e5f\u4f9d\u7136\u7559\u5728\u8fdb\u7a0b\u8868\u4e2d\u3002<\/p>\n

\u90a3\u4e48\uff0c\u8fd9\u4e9b\u5b8c\u6210\u4e86\u751f\u547d\u5468\u671f\u4f46\u5374\u4f9d\u7136\u7559\u5728\u8fdb\u7a0b\u8868\u4e2d\u7684\u8fdb\u7a0b\uff0c\u6211\u4eec\u79f0\u4e4b\u4e3a \u201c\u50f5\u5c38\u8fdb\u7a0b\u201d\u3002<\/p>\n

\"\"<\/a><\/p>\n

\u5185\u5bb9<\/strong><\/div>\n

\u5b83\u4eec\u662f\u5982\u4f55\u4ea7\u751f\u7684\uff1f<\/h3>\n

\u5f53\u4f60\u8fd0\u884c\u4e00\u4e2a\u7a0b\u5e8f\u65f6\uff0c\u5b83\u4f1a\u4ea7\u751f\u4e00\u4e2a\u7236\u8fdb\u7a0b\u4ee5\u53ca\u5f88\u591a\u5b50\u8fdb\u7a0b\u3002 \u6240\u6709\u8fd9\u4e9b\u5b50\u8fdb\u7a0b\u90fd\u4f1a\u6d88\u8017\u5185\u6838\u5206\u914d\u7ed9\u5b83\u4eec\u7684\u5185\u5b58\u548c CPU \u8d44\u6e90\u3002<\/p>\n

\u8fd9\u4e9b\u5b50\u8fdb\u7a0b\u5b8c\u6210\u6267\u884c\u540e\u4f1a\u53d1\u9001\u4e00\u4e2a Exit \u4fe1\u53f7\u7136\u540e\u6b7b\u6389\u3002\u8fd9\u4e2a Exit \u4fe1\u53f7\u9700\u8981\u88ab\u7236\u8fdb\u7a0b\u6240\u8bfb\u53d6\u3002\u7236\u8fdb\u7a0b\u9700\u8981\u968f\u540e\u8c03\u7528 wait<\/code> \u547d\u4ee4\u6765\u8bfb\u53d6\u5b50\u8fdb\u7a0b\u7684\u9000\u51fa\u72b6\u6001\uff0c\u5e76\u5c06\u5b50\u8fdb\u7a0b\u4ece\u8fdb\u7a0b\u8868\u4e2d\u79fb\u9664\u3002<\/p>\n

\u82e5\u7236\u8fdb\u7a0b\u6b63\u786e\u7b2c\u8bfb\u53d6\u4e86\u5b50\u8fdb\u7a0b\u7684 Exit \u4fe1\u53f7\uff0c\u5219\u5b50\u8fdb\u7a0b\u4f1a\u4ece\u8fdb\u7a0b\u8868\u4e2d\u5220\u6389\u3002<\/p>\n

\u4f46\u82e5\u7236\u8fdb\u7a0b\u672a\u80fd\u8bfb\u53d6\u5230\u5b50\u8fdb\u7a0b\u7684 Exit \u4fe1\u53f7\uff0c\u5219\u8fd9\u4e2a\u5b50\u8fdb\u7a0b\u867d\u7136\u5b8c\u6210\u6267\u884c\u5904\u4e8e\u6b7b\u4ea1\u7684\u72b6\u6001\uff0c\u4f46\u4e5f\u4e0d\u4f1a\u4ece\u8fdb\u7a0b\u8868\u4e2d\u5220\u6389\u3002<\/p>\n

\u50f5\u5c38\u8fdb\u7a0b\u5bf9\u7cfb\u7edf\u6709\u5bb3\u5417\uff1f<\/strong><\/div>\n

\u4e0d\u4f1a<\/strong>\u3002\u7531\u4e8e\u50f5\u5c38\u8fdb\u7a0b\u5e76\u4e0d\u505a\u4efb\u4f55\u4e8b\u60c5\uff0c \u4e0d\u4f1a\u4f7f\u7528\u4efb\u4f55\u8d44\u6e90\u4e5f\u4e0d\u4f1a\u5f71\u54cd\u5176\u5b83\u8fdb\u7a0b\uff0c \u56e0\u6b64\u5b58\u5728\u50f5\u5c38\u8fdb\u7a0b\u4e5f\u6ca1\u4ec0\u4e48\u574f\u5904\u3002 \u4e0d\u8fc7\u7531\u4e8e\u8fdb\u7a0b\u8868\u4e2d\u7684\u9000\u51fa\u72b6\u6001\u4ee5\u53ca\u5176\u5b83\u4e00\u4e9b\u8fdb\u7a0b\u4fe1\u606f\u4e5f\u662f\u5b58\u50a8\u5728\u5185\u5b58\u4e2d\u7684\uff0c\u56e0\u6b64\u5b58\u5728\u592a\u591a\u50f5\u5c38\u8fdb\u7a0b\u6709\u65f6\u4e5f\u4f1a\u662f\u4e00\u4e9b\u95ee\u9898\u3002<\/p>\n

\u4f60\u53ef\u4ee5\u60f3\u8c61\u6210\u8fd9\u6837\uff1a<\/strong><\/p>\n

\u201c\u4f60\u662f\u4e00\u5bb6\u5efa\u7b51\u516c\u53f8\u7684\u8001\u677f\u3002\u4f60\u6bcf\u5929\u6839\u636e\u5de5\u4eba\u4eec\u7684\u5de5\u4f5c\u91cf\u6765\u652f\u4ed8\u5de5\u8d44\u3002 \u6709\u4e00\u4e2a\u5de5\u4eba\u6bcf\u5929\u6765\u5230\u65bd\u5de5\u73b0\u573a\uff0c\u5c31\u5750\u5728\u90a3\u91cc\uff0c \u4f60\u4e0d\u7528\u4ed8\u94b1\uff0c \u4ed6\u4e5f\u4e0d\u505a\u4efb\u4f55\u5de5\u4f5c\u3002 \u4ed6\u53ea\u662f\u6bcf\u5929\u90fd\u6765\u7136\u540e\u5446\u5750\u5728\u90a3\uff0c\u4ec5\u6b64\u800c\u5df2\uff01\u201d<\/p>\n

\u8fd9\u4e2a\u5de5\u4eba\u5c31\u662f\u50f5\u5c38\u8fdb\u7a0b\u7684\u4e00\u4e2a\u6d3b\u751f\u751f\u7684\u4f8b\u5b50\u3002\u4f46\u662f<\/strong>\uff0c \u5982\u679c\u4f60\u6709\u5f88\u591a\u50f5\u5c38\u5de5\u4eba\uff0c \u4f60\u7684\u5efa\u8bbe\u5de5\u5730\u5c31\u4f1a\u5f88\u62e5\u5835\u4ece\u800c\u8ba9\u90a3\u4e9b\u6b63\u5e38\u7684\u5de5\u4eba\u96be\u4ee5\u5de5\u4f5c\u3002<\/p>\n

\u90a3\u4e48\u5982\u4f55\u627e\u51fa\u50f5\u5c38\u8fdb\u7a0b\u5462\uff1f<\/strong><\/div>\n

\u6253\u5f00\u7ec8\u7aef\u5e76\u8f93\u5165\u4e0b\u9762\u547d\u4ee4:
\nps aux | grep Z<\/code><\/p>\n

\u4f1a\u5217\u51fa\u8fdb\u7a0b\u8868\u4e2d\u6240\u6709\u50f5\u5c38\u8fdb\u7a0b\u7684\u8be6\u7ec6\u5185\u5bb9\u3002<\/p>\n

\u5982\u4f55\u6740\u6389\u50f5\u5c38\u8fdb\u7a0b\uff1f<\/strong><\/div>\n

\u6b63\u5e38\u60c5\u51b5\u4e0b\u6211\u4eec\u53ef\u4ee5\u7528 SIGKILL<\/code>
\n\u4fe1\u53f7\u6765\u6740\u6b7b\u8fdb\u7a0b\uff0c\u4f46\u662f\u50f5\u5c38\u8fdb\u7a0b\u5df2\u7ecf\u6b7b\u4e86\uff0c \u4f60\u4e0d\u80fd\u6740\u6b7b\u5df2\u7ecf\u6b7b\u6389\u7684\u4e1c\u897f\u3002 \u56e0\u6b64\u4f60\u9700\u8981\u8f93\u5165\u7684\u547d\u4ee4\u5e94\u8be5\u662f
\nkill -s SIGCHLD pid<\/code><\/p>\n

\u5c06\u8fd9\u91cc\u7684 pid \u66ff\u6362\u6210\u7236\u8fdb\u7a0b\u7684\u8fdb\u7a0b id\uff0c\u8fd9\u6837\u7236\u8fdb\u7a0b\u5c31\u4f1a\u5220\u9664\u6240\u6709\u4ee5\u53ca\u5b8c\u6210\u5e76\u6b7b\u6389\u7684\u5b50\u8fdb\u7a0b\u4e86\u3002<\/p>\n

\u4f60\u53ef\u4ee5\u628a\u5b83\u60f3\u8c61\u6210\uff1a<\/p>\n

\"\u4f60\u5728\u9053\u8def\u4e2d\u95f4\u53d1\u73b0\u4e00\u5177\u5c38\u4f53\uff0c\u4e8e\u662f\u4f60\u8054\u7cfb\u4e86\u6b7b\u8005\u7684\u5bb6\u5c5e\uff0c\u968f\u540e\u4ed6\u4eec\u5c31\u4f1a\u5c06\u5c38\u4f53\u5e26\u79bb\u9053\u8def\u4e86\u3002\"<\/p>\n

\u4e0d\u8fc7\u8bb8\u591a\u7a0b\u5e8f\u5199\u7684\u4e0d\u662f\u90a3\u4e48\u597d\uff0c\u65e0\u6cd5\u5220\u6389\u8fd9\u4e9b\u5b50\u50f5\u5c38\uff08\u5426\u5219\u4f60\u4e00\u5f00\u59cb\u4e5f\u89c1\u4e0d\u5230\u8fd9\u4e9b\u50f5\u5c38\u4e86\uff09\u3002 \u56e0\u6b64\u786e\u4fdd\u5220\u9664\u5b50\u50f5\u5c38\u7684\u552f\u4e00\u65b9\u6cd5\u5c31\u662f\u6740\u6389\u5b83\u4eec\u7684\u7236\u8fdb\u7a0b\u3002<\/p>\n


\n

via: http:\/\/www.linuxandubuntu.com\/home\/what-are-zombie-processes-and-how-to-find-kill-zombie-processes<\/a><\/p>\n

\u4f5c\u8005\uff1alinuxandubuntu<\/a> \u8bd1\u8005\uff1alujun9972<\/a> \u6821\u5bf9\uff1awxy<\/a><\/p>\n

\u672c\u6587\u7531 LCTT<\/a> \u539f\u521b\u7f16\u8bd1\uff0cLinux\u4e2d\u56fd<\/a> \u8363\u8a89\u63a8\u51fa<\/p>\n

\n

\u539f\u6587\u6765\u81ea\uff1ahttps:\/\/linux.cn\/article-9143-1.html<\/a><\/p>\n

\u672c\u6587\u5730\u5740\uff1ahttp:\/\/lrxjmw.cn\/zombie-linux.html<\/a>\u7f16\u8f91\uff1a\u4efb\u7ef4\u56fd\uff0c\u5ba1\u6838\u5458\uff1a\u9004\u589e\u5b9d<\/span><\/p>\n<\/blockquote>\n","protected":false},"excerpt":{"rendered":"

\u5bfc\u8bfb \u5982\u679c\u4f60\u7ecf\u5e38\u4f7f\u7528 Linux\uff0c\u4f60\u5e94\u8be5\u9047\u5230\u8fd9\u4e2a\u672f\u8bed\u201c\u50f5\u5c38\u8fdb\u7a0b\u201d\u3002 \u90a3\u4e48\u4ec0\u4e48\u662f\u50f5\u5c38\u8fdb\u7a0b\uff1f \u5b83\u4eec\u662f\u600e\u4e48\u4ea7\u751f\u7684\uff1f […]<\/p>\n","protected":false},"author":63,"featured_media":90346,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"_acf_changed":false,"footnotes":""},"categories":[55],"tags":[],"class_list":["post-90445","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-thread"],"acf":[],"_links":{"self":[{"href":"https:\/\/lrxjmw.cn\/wp-json\/wp\/v2\/posts\/90445","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/lrxjmw.cn\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/lrxjmw.cn\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/lrxjmw.cn\/wp-json\/wp\/v2\/users\/63"}],"replies":[{"embeddable":true,"href":"https:\/\/lrxjmw.cn\/wp-json\/wp\/v2\/comments?post=90445"}],"version-history":[{"count":4,"href":"https:\/\/lrxjmw.cn\/wp-json\/wp\/v2\/posts\/90445\/revisions"}],"predecessor-version":[{"id":90464,"href":"https:\/\/lrxjmw.cn\/wp-json\/wp\/v2\/posts\/90445\/revisions\/90464"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/lrxjmw.cn\/wp-json\/wp\/v2\/media\/90346"}],"wp:attachment":[{"href":"https:\/\/lrxjmw.cn\/wp-json\/wp\/v2\/media?parent=90445"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/lrxjmw.cn\/wp-json\/wp\/v2\/categories?post=90445"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/lrxjmw.cn\/wp-json\/wp\/v2\/tags?post=90445"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}