Problem in installing pip in Ubuntu 16.04

12,673

Solution 1

Had a similar problem a while ago. If I remember correctly, it was solved by purging and reinstalling with

sudo apt-get purge python-pip

followed by

sudo apt-get update
sudo apt-get install python-pip

Purge removes configuration files as well as uninstalling the package.

Solution 2

Probably pip is hashed at its previous location. To confirm, run type pip. The output may be

pip is hashed (/home/coder/.local/bin/pip)

If yes, run hash -d pip. That will fix it.

Share:
12,673

Related videos on Youtube

john400
Author by

john400

Updated on September 18, 2022

Comments

  • john400
    john400 over 1 year

    Actually, I wanted to install pip because I needed to install pycurl which was needed for using Wfuzz. The main fact is that I need to install pip.

    I remembered that I had already installed pip once but since I was getting some kind of weird errors, I just removed pip using

    sudo apt-get remove python-pip
    

    But now, when I am using

    sudo apt-get install python-pip
    

    The pip V 8.1 is getting installed, but when I am trying to use it, the error shows.

    bash: /home/coder/.local/bin/pip: No such file or directory
    

    I already went through this: Problem installing pip: pip command not found

    But there are already 3 pip files at that location, named pip, pip2 and pip2.7

    So what should I do now? Any help will be much appreciated as I really need to use the tool wfuzz for other purposes.

    OS: Ubuntu 16.04

    • Dadep
      Dadep almost 6 years
    • john400
      john400 almost 6 years
      @Dadep. That problem seems different though I tried purging and reinstalling yet no success
    • Dadep
      Dadep almost 6 years
      Did you try to install with yum or like this : pip.pypa.io/en/stable/installing ?
    • john400
      john400 almost 6 years
      Hey I was able to install it. I think I just closed and opened my terminal again. Thanks for the help too. But now I am having problems with installing pycurl using the command >pip install pycurl. But its giving some error
    • Dadep
      Dadep almost 6 years
      just open new question, for pycurl installation if you need help
    • john400
      john400 almost 6 years
      Everything worked out for me. I got the same error question here stackoverflow.com/questions/37669428/…
  • Pablo Bianchi
    Pablo Bianchi over 5 years
    Then I had to fix /usr/bin/pip.