OSError 'No child processes' in multiprocessing/forking.py
On Oracle Linux 5.9 the salt-minion displays an OSError when the tune_in method is called.
Trackback:
[CRITICAL] Traceback (most recent call last):
File "/usr/lib/python2.6/site-packages/salt/minion.py", line 792, in tune_in
multiprocessing.active_children()
File "/usr/lib64/python2.6/multiprocessing/process.py", line 43, in active_children
_cleanup()
File "/usr/lib64/python2.6/multiprocessing/process.py", line 53, in _cleanup
if p._popen.poll() is not None:
File "/usr/lib64/python2.6/multiprocessing/forking.py", line 106, in poll
pid, sts = os.waitpid(self.pid, flag)
OSError: [Errno 10] No child processes
Platform:
Minion:
Oracle Linux 5.9
Latest Salt Dev branch 0.13.0-601-g233f7e2
zeromq-2.1.9-1.el5
Master:
CentOS 6.3
Latest Salt Dev branch 0.13.0-601-g233f7e2
zeromq-2.1.9-1.el6.x86_64
~Rob
@thatch45 want me to cherry-pick my fix?
This issue, goes deeper
http://stackoverflow.com/questions/1008858/popen-communicate-throws-oserror-errno-10-no-child-processes#4
We need to momentarily, not handle SIGCHLD when calling communicate, but what will this trigger!?
This will return us to where we were before where we would have a few zombie processes around for a few seconds until they are cleaned up.
On Fri, Mar 8, 2013 at 1:25 PM, Pedro Algarvio [email protected]:
We need to momentarily, not handle SIGCHLD when calling communicate, but what will this trigger!?
— Reply to this email directly or view it on GitHubhttps://github.com/saltstack/salt/issues/4008#issuecomment-14643569 .
Dave Boucha | Sr. Engineer
5272 South College Drive, Suite 301 | Murray, UT 84123 office 801-305-3563 [email protected] | www.saltstack.com http://saltstack.com/
This issue has been fixed for python 2.7.
Two options:
- Force an extra dependency on python-subprocess32 for python 2.6
- Under python 2.6, we document and accept that some children zombies will exist within some time frames, ie, until we call
multiprocessing.active_children()since we should not catch and ignoreSIGCHLD.
#4022 should take care of this, still, can any you of try my fix from my fork, branch issues/4008 to confirm if I addressed all problems?
@s0undt3ch Ill give it a try on my dev environment later today. Thanks everyone for looking into this!
This issue can be closed, current git develop is fixed.
@s0undt3ch Finally was able to test this and it all looks great on my end, thanks again!