Linux - NewbieThis Linux forum is for members that are new to Linux.
Just starting out and have a question?
If it is not in the man pages or the how-to's this is the place!
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
I am running Ubuntu 16.10 with Anaconda installed and am attempting to update pip using the command line
Quote:
sudo pip install --upgrade pip
which doesn't seem to work at all .
I have also tried
Quote:
pip install --upgrade pip
(output below).
beyond that I have tried in an attempt to change the permissions on that directory.
Quote:
sudo find /home/ptahx/anaconda3 -type d -exec chmod 755 {} \;
I'm at a loss as to what to attempt next, I've tried reading up on it but haven't had much luck beyond what I have listed above. Any ideas or help would be appreciated.
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/home/ptahx/anaconda3/lib/python3.5/site-packages/pip/basecommand.py", line 215, in main
status = self.run(options, args)
File "/home/ptahx/anaconda3/lib/python3.5/site-packages/pip/commands/install.py", line 317, in run
prefix=options.prefix_path,
File "/home/ptahx/anaconda3/lib/python3.5/site-packages/pip/req/req_set.py", line 736, in install
requirement.uninstall(auto_confirm=True)
File "/home/ptahx/anaconda3/lib/python3.5/site-packages/pip/req/req_install.py", line 742, in uninstall
paths_to_remove.remove(auto_confirm)
File "/home/ptahx/anaconda3/lib/python3.5/site-packages/pip/req/req_uninstall.py", line 115, in remove
renames(path, new_path)
File "/home/ptahx/anaconda3/lib/python3.5/site-packages/pip/utils/__init__.py", line 267, in renames
shutil.move(old, new)
File "/home/ptahx/anaconda3/lib/python3.5/shutil.py", line 553, in move
os.unlink(src)
PermissionError: [Errno 13] Permission denied: '/home/ptahx/anaconda3/bin/pip'
You are using pip version 8.1.2, however version 9.0.1 is available.
You should consider upgrading via the 'pip install --upgrade pip' command.
ptahx@PtahXGamer:~$ apt-get upgrade pip
E: Could not open lock file /var/lib/dpkg/lock - open (13: Permission denied)
E: Unable to lock the administration directory (/var/lib/dpkg/), are you root?
ptahx@PtahXGamer:~$ sudo apt-get upgrade pip
[sudo] password for ptahx:
Reading package lists... Done
Building dependency tree
Reading state information... Done
E: Unable to locate package pip
ptahx@PtahXGamer:~$
then reinstalled anaconda (added to path as well) interestingly enough it now made a separate directory called /home/conda instead of /home/anaconda
Quote:
bash Anaconda3-4.2.0-Linux-x86_64.sh
result still hasn't corrected the permissions issue, it still won't update tot he 9.0.1 as listed below. Thank you for your help - back to my fuddling
Quote:
ptahx@PtahXGamer:~$ sudo python3 -m pip install pip
The directory '/home/ptahx/.cache/pip/http' or its parent directory is not owned by the current user and the cache has been disabled. Please check the permissions and owner of that directory. If executing pip with sudo, you may want sudo's -H flag.
The directory '/home/ptahx/.cache/pip' or its parent directory is not owned by the current user and caching wheels has been disabled. check the permissions and owner of that directory. If executing pip with sudo, you may want sudo's -H flag.
Requirement already satisfied (use --upgrade to upgrade): pip in /usr/lib/python3/dist-packages
You are using pip version 8.1.2, however version 9.0.1 is available.
You should consider upgrading via the 'pip install --upgrade pip' command.
ptahx@PtahXGamer:~$ python3 -m pip install pip
Collecting pip
Using cached pip-9.0.1-py2.py3-none-any.whl
Installing collected packages: pip
Successfully installed pip-8.1.2
You are using pip version 8.1.2, however version 9.0.1 is available.
You should consider upgrading via the 'pip install --upgrade pip' command.
ptahx@PtahXGamer:~$ pip install --upgrade pip
bash: /usr/bin/pip: No such file or directory
ptahx@PtahXGamer:~$ sudo pip install --upgrade pip
sudo: pip: command not found
ptahx@PtahXGamer:~$ apt-get install --upgrade pip
E: Could not open lock file /var/lib/dpkg/lock - open (13: Permission denied)
E: Unable to lock the administration directory (/var/lib/dpkg/), are you root?
ptahx@PtahXGamer:~$ sudo apt-get install --upgrade pip
Reading package lists... Done
Building dependency tree
Reading state information... Done
E: Unable to locate package pip
ptahx@PtahXGamer:~$
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.