From: Navkirat Singh on 24 Jul 2010 19:07 Hi, I have been meddling around with forking and multiprocessing. Now both of them spawn new processes from parent (atleast from what I have understood). I have been able to reproduce a zombie state in a fork with: import os,time print('before fork',os.getpid()) pid = os.fork() if pid: print('child: ',pid) time.sleep(120) Now doing a ps ax | grep <pid> I can find a zombie child process, but I am not being able to reproduce the same with multiprocessing. Am I missing something? Or multiprocessing does not have the zombie problem? Regards, Nav
From: Navkirat Singh on 24 Jul 2010 19:11 OK I wanted zombie processes and have been able to regenerate them with multiprocessing. Now lets see how I can handle them. Nav On 25-Jul-2010, at 4:37 AM, Navkirat Singh wrote: > Hi, > > I have been meddling around with forking and multiprocessing. Now both of them spawn new processes from parent (atleast from what I have understood). I have been able to reproduce a zombie state in a fork with: > > import os,time > > print('before fork',os.getpid()) > > pid = os.fork() > > if pid: > print('child: ',pid) > time.sleep(120) > > Now doing a ps ax | grep <pid> I can find a zombie child process, but I am not being able to reproduce the same with multiprocessing. Am I missing something? Or multiprocessing does not have the zombie problem? > > Regards, > Nav
From: Chris Rebert on 24 Jul 2010 19:38 On Sat, Jul 24, 2010 at 4:11 PM, Navkirat Singh <navkirats(a)gmail.com> wrote: > OK I wanted zombie processes <snip> > Now lets see how I can handle them. "Paging Dr. Frankenstein. Dr. Frankenstein to the lab. Paging Dr. Frankenstein." Cheers, Chris -- Most people try to /avoid/ making zombies.
From: Navkirat Singh on 24 Jul 2010 19:43 I want to kill Zombies....so first I have to create them...simple law of nature.... On 25-Jul-2010, at 5:08 AM, Chris Rebert wrote: > On Sat, Jul 24, 2010 at 4:11 PM, Navkirat Singh <navkirats(a)gmail.com> wrote: >> OK I wanted zombie processes > <snip> >> Now lets see how I can handle them. > > "Paging Dr. Frankenstein. Dr. Frankenstein to the lab. Paging Dr. Frankenstein." > > Cheers, > Chris > -- > Most people try to /avoid/ making zombies.
From: Thomas Jollans on 24 Jul 2010 19:51
On 07/25/2010 01:43 AM, Navkirat Singh wrote: > I want to kill Zombies....so first I have to create them...simple law of nature.... You can't kill a zombie. That's why we call them zombies, as opposed to, say, daemons. > > > On 25-Jul-2010, at 5:08 AM, Chris Rebert wrote: > >> On Sat, Jul 24, 2010 at 4:11 PM, Navkirat Singh <navkirats(a)gmail.com> wrote: >>> OK I wanted zombie processes >> <snip> >>> Now lets see how I can handle them. >> >> "Paging Dr. Frankenstein. Dr. Frankenstein to the lab. Paging Dr. Frankenstein." >> >> Cheers, >> Chris >> -- >> Most people try to /avoid/ making zombies. > |