# For those having paramiko issues, I can't reproduce, but please try this...

**URL:** <https://forum.ansible.com/t/for-those-having-paramiko-issues-i-cant-reproduce-but-please-try-this/11378>\
**Category:** Ansible Project\
**Created:** [March 28, 2012, 11:52pm UTC](https://forum.ansible.com/t/for-those-having-paramiko-issues-i-cant-reproduce-but-please-try-this/11378 "2012-03-28T23:52:29Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![Michael\_DeHaan](https://avatars.discourse-cdn.com/v4/letter/m/c4cdca/32.png) [@Michael\_DeHaan](https://forum.ansible.com/u/Michael_DeHaan)\
**Post date:** [March 28, 2012, 11:52pm UTC](https://forum.ansible.com/t/for-those-having-paramiko-issues-i-cant-reproduce-but-please-try-this/11378/1 "2012-03-28T23:52:29Z")

</div>

Explanation -- the paramiko error says please try to run  
"Random.atfork()" which is a pyCrypto thing. It seems to be a newer  
Pycrypto issue (CentOS 6 does not have this function, it seems), not  
even a paramiko bug at all. Given it seems to be related to forking,  
I'd like to know if this works, if not, it may be a starting point for  
something that does actually work with the paramiko issue.

I have attached a patch I would like you to test.

BTW, here's the part of the PyCrypto code that is being annoying:

&nbsp;&nbsp;def \_check\_pid(self):  
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;# Lame fork detection to remind developers to invoke Random.atfork()  
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;# after every call to os.fork(). Note that this check is not reliable,  
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;# since process IDs can be reused on most operating systems.

---

<div class="post-metadata">

**Author:** ![Michael\_DeHaan](https://avatars.discourse-cdn.com/v4/letter/m/c4cdca/32.png) [@Michael\_DeHaan](https://forum.ansible.com/u/Michael_DeHaan)\
**Post date:** [March 29, 2012, 12:39am UTC](https://forum.ansible.com/t/for-those-having-paramiko-issues-i-cant-reproduce-but-please-try-this/11378/2 "2012-03-29T00:39:16Z")

</div>

I went ahead and pushed this _attempted_ fix for those using git, we can back it off it proves not useful.

It seems like a pycrypto slash paramiko mismatch, more or less, so a newest paramiko should do the right thing. I’ve heard people say this does NOT fix the problem though, hence this attempted workaround.

Anyhow, let me know…

–Michael

---

<div class="post-metadata">

**Author:** ![Matthew\_Williams](https://avatars.discourse-cdn.com/v4/letter/m/a3d4f5/32.png) [@Matthew\_Williams](https://forum.ansible.com/u/Matthew_Williams)\
**Post date:** [March 29, 2012, 10:57pm UTC](https://forum.ansible.com/t/for-those-having-paramiko-issues-i-cant-reproduce-but-please-try-this/11378/3 "2012-03-29T22:57:12Z")

</div>

For the record, this fix works for me, on Ubuntu Oneiric (11.10) with latest Paramiko (1.7.7.1).
