Can't cleanup a zombie process whose parent is init

Viewed 11949

I have a zombie process:

$ ps aux | grep Zl
root      6641  122  0.0  0 0 ? Zl   08:57 371:10 [ovs_dpdk] <defunct>

And, its parent looks like init

$ pstree
init─┬─acpid
     ├─atd
     ├─cron
     ├─dbus-daemon
     ├─dnsmasq
     ├─6*[getty]
     ├─irqbalance
     ├─libvirtd───10*[{libvirtd}]
     ├─ovs_dpdk───{ovs_dpdk}               <==== here
     ├─rpc.idmapd

But, kill -9 does not kill him...

sudo kill -9 6641

I'm stumped here, any help?

4 Answers

Zombie can't be clean up by Kill command. If it's a child process of Init process (pid = 1) then it should auto cleanup.

OR As init process is not cleaning up Just Reboot System.

if the Zombies got generated again then might be code bug. You need to look into code issue : as Parent is not waiting for getting the return exit code by child.

As a reference various example is quoted here Generation and cleanup of Zombies n C might be helpful.

Related