easy_install pip == [Errno 8] nodename nor servname provided, or not known

Andrei picture Andrei · Aug 13, 2012 · Viewed 18.7k times · Source

I have troubles installing pip for python 2.7.3 installed via pythonbrew:

pythonbrew update --master
pythonbrew install 2.7.3 --force

This fails on the final stage hanging when trying to fetch pip from pip.openplans.org:

Installed /Users/andrei/.pythonbrew/pythons/Python-2.7.3/lib/python2.7/site-packages/distribute-0.6.28-py2.7.egg
Processing dependencies for distribute==0.6.28
Finished processing dependencies for distribute==0.6.28
After install bootstrap.
Don't have permissions to write /Users/andrei/.pythonbrew/pythons/Python-2.7.3/lib/python2.7/site-packages/setuptools-0.6c11-py2.7.egg-info, skipping
Creating /Users/andrei/.pythonbrew/pythons/Python-2.7.3/lib/python2.7/site-packages/setuptools-0.6c11-py2.7.egg-info
Creating /Users/andrei/.pythonbrew/pythons/Python-2.7.3/lib/python2.7/site-packages/setuptools.pth
Searching for pip
Reading http://pypi.python.org/simple/pip/
Reading http://pip.openplans.org
Download error on http://pip.openplans.org: [Errno 8] nodename nor servname provided, or not known -- Some packages may not be found!
Reading http://pip.openplans.org
Download error on http://pip.openplans.org: [Errno 8] nodename nor servname provided, or not known -- Some packages may not be found!
Reading http://pip.openplans.org
...

Running easy_install pip also results in the same error. Of course, I can still clone pip repo and install it manually, but would be nice to know why it fails via easy_install. Any idea?


Update:

$ host pip.openplans.org
pip.openplans.org is an alias for puffin.oddbird.net.
puffin.oddbird.net has address 173.203.85.138

Answer

WindChimes picture WindChimes · Aug 15, 2016

I had a similar problem; the command was failing in iTerm2, but not in the default OS X Terminal. Restarting iTerm2 fixed the issue.