w

curl https://bootstrap.pypa.io/get-pip.py > curl_get-pip.py
python curl_get-pip.py

https://pip.pypa.io/en/stable/installing/

curl https://bootstrap.pypa.io/get-pip.py > curl_get-pip.py

wuser@ubuntu:~$ pip install -U pip setuptools
The program 'pip' is currently not installed. You can install it by typing:
sudo apt install python-pip
wuser@ubuntu:~$ python get-pip.py
python: can't open file 'get-pip.py': [Errno 2] No such file or directory
wuser@ubuntu:~$ python https://bootstrap.pypa.io/get-pip.py
python: can't open file 'https://bootstrap.pypa.io/get-pip.py': [Errno 2] No such file or directory
wuser@ubuntu:~$ pwd
/home/wuser
wuser@ubuntu:~$ ll
total
drwxr-xr-x wuser wuser May : ./
drwxr-xr-x root root May : ../
-rw-r--r-- wuser wuser May : .bash_logout
-rw-r--r-- wuser wuser May : .bashrc
drwx------ wuser wuser May : .cache/
-rw-rw-r-- wuser wuser May : .dbshell
-rw------- wuser wuser May : .mongorc.js
-rw-r--r-- wuser wuser May : .profile
-rw-r--r-- wuser wuser May : .sudo_as_admin_successful
wuser@ubuntu:~$ curl https://bootstrap.pypa.io/get-pip.py > curl_get-pip.py
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
1558k 1558k 196k :: :: --:--:-- 331k
wuser@ubuntu:~$ ls
curl_get-pip.py
wuser@ubuntu:~$ python curl_get-pip.py
Collecting pip
Downloading pip-9.0.-py2.py3-none-any.whl (.3MB)
% |████████████████████████████████| .3MB 18kB/s
Collecting setuptools
Downloading setuptools-35.0.-py2.py3-none-any.whl (390kB)
% |████████████████████████████████| 399kB 59kB/s
Collecting wheel
Downloading wheel-0.29.-py2.py3-none-any.whl (66kB)
% |████████████████████████████████| 71kB 22kB/s
Collecting appdirs>=1.4. (from setuptools)
Downloading appdirs-1.4.-py2.py3-none-any.whl
Collecting packaging>=16.8 (from setuptools)
Downloading packaging-16.8-py2.py3-none-any.whl
Collecting six>=1.6. (from setuptools)
Downloading six-1.10.-py2.py3-none-any.whl
Collecting pyparsing (from packaging>=16.8->setuptools)
Downloading pyparsing-2.2.-py2.py3-none-any.whl (56kB)
% |████████████████████████████████| 61kB 72kB/s
Installing collected packages: pip, appdirs, pyparsing, six, packaging, setuptools, wheel
Exception:
Traceback (most recent call last):
File "/tmp/tmpO7xHXx/pip.zip/pip/basecommand.py", line , in main
status = self.run(options, args)
File "/tmp/tmpO7xHXx/pip.zip/pip/commands/install.py", line , in run
prefix=options.prefix_path,
File "/tmp/tmpO7xHXx/pip.zip/pip/req/req_set.py", line , in install
**kwargs
File "/tmp/tmpO7xHXx/pip.zip/pip/req/req_install.py", line , in install
self.move_wheel_files(self.source_dir, root=root, prefix=prefix)
File "/tmp/tmpO7xHXx/pip.zip/pip/req/req_install.py", line , in move_wheel_files
isolated=self.isolated,
File "/tmp/tmpO7xHXx/pip.zip/pip/wheel.py", line , in move_wheel_files
clobber(source, lib_dir, True)
File "/tmp/tmpO7xHXx/pip.zip/pip/wheel.py", line , in clobber
ensure_dir(destdir)
File "/tmp/tmpO7xHXx/pip.zip/pip/utils/__init__.py", line , in ensure_dir
os.makedirs(path)
File "/usr/lib/python2.7/os.py", line , in makedirs
mkdir(name, mode)
OSError: [Errno ] Permission denied: '/usr/local/lib/python2.7/dist-packages/pip'
wuser@ubuntu:~$ sudo python curl_get-pip.py
The directory '/home/wuser/.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/wuser/.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.
Collecting pip
Downloading pip-9.0.-py2.py3-none-any.whl (.3MB)
% |████████████████████████████████| .3MB 18kB/s
Collecting setuptools
Downloading setuptools-35.0.-py2.py3-none-any.whl (390kB)
% |████████████████████████████████| 399kB 17kB/s
Collecting wheel
Downloading wheel-0.29.-py2.py3-none-any.whl (66kB)
% |████████████████████████████████| 71kB 10kB/s
Collecting appdirs>=1.4. (from setuptools)
Downloading appdirs-1.4.-py2.py3-none-any.whl
Collecting packaging>=16.8 (from setuptools)
Downloading packaging-16.8-py2.py3-none-any.whl
Collecting six>=1.6. (from setuptools)
Downloading six-1.10.-py2.py3-none-any.whl
Collecting pyparsing (from packaging>=16.8->setuptools)
Downloading pyparsing-2.2.-py2.py3-none-any.whl (56kB)
% |████████████████████████████████| 61kB 17kB/s
Installing collected packages: pip, appdirs, pyparsing, six, packaging, setuptools, wheel
Successfully installed appdirs-1.4. packaging-16.8 pip-9.0. pyparsing-2.2. setuptools-35.0. six-1.10. wheel-0.29.
wuser@ubuntu:~$

python curl_get-pip.py Installing with get-pip.py的更多相关文章

  1. [python] Ubuntu 环境下安装 python3.5 + pip

    一般情况下先添加PPA,但是我添加PPA会报错: sudo add-apt-repository ppa:fkrull/deadsnakes ubuntu add-apt-repository: co ...

  2. Python之No module named setuptools 安装pip

    早上运行程序的时候发现没有引入相应的module,然后使用pip去安装的时候发现自己没有在安装pip,于是在自己的软件群里边找见了pip安装包,在pip的解压目录下运行python setup.py ...

  3. 【转】python多版本并存,python3安装pip

    python3 与 pip3 安装与使用   1. yum -y install openssl* (pip依赖ssl环境) 2.编译安装python3 下载地址:https://www.python ...

  4. Python的包管理工具easy_install, setuptools, pip,distribute介绍

    1.相互之间的关联 easy_install, setuptools, pip,distribute,这几个工具的联系,如下图: 可以看到distribute是setuptools的取代,pip是ea ...

  5. 解决安装虚拟环境出现的问题(OSError: Command /home/python/.virtua...ngo3_web/bin/python3 - setuptools pkg_resources pip wheel failed with error code 2)

    python3的报错解决: OSError: Command /home/python/.virtua...ngo3_web/bin/python3 - setuptools pkg_resource ...

  6. py安装以及配置pip环境变量

    安装python,安装包链接:https://pan.baidu.com/s/1u4tA-FJMxtrtJTap-zFh3g 密码:gh1c 默然安装到了C盘 安装pycharm:安装包链接:链接:h ...

  7. Python项目生成requirements.txt文件及pip升级问题解决及流程

    缘由:新项目使用Python, PC上的python包不全,需要通过requirements.txt文件指定安装所需包 pip安装遇到一些坑 一.直接使用pip包管理工具生成requirements. ...

  8. pip Read timed out 和 pip 源

    解决方法,设置超时时间 pip --default-timeout=100 install -U Pillow 安装时指定源(--index-url) #例如安装scipy时使用豆瓣的源 pip in ...

  9. 【转】python:让源码更安全之将py编译成so

    python:让源码更安全之将py编译成so 应用场景 Python是一种面向对象的解释型计算机程序设计语言,具有丰富和强大的库,使用其开发产品快速高效. python的解释特性是将py编译为独有的二 ...

随机推荐

  1. nginx知识问答

    1.请解释一下什么是Nginx? 答:Nginx是一个web服务器和反向代理服务器,用于HTTP.HTTPS.SMTP.POP3和IMAP协议.2.请列举Nginx的一些特性? 答:Nginx服务器的 ...

  2. 工作日记之查看Linux系统里面的启动频率2017_02_07

    链接:http://www.jb51.net/LINUXjishu/19905.html 查看Linux里面的batch: cat /etc/crontab (1)0 19 * * 6 root /d ...

  3. P3588 [POI2015]PUS(拓扑排序+线段树)

    P3588 [POI2015]PUS 对于每个$(l,r,k)$,将$k$个位置向剩下$r-l-k+1$个位置连边,边权为$1$,这样就保证$k$个位置比剩下的大 先给所有位置填$1e9$保证最优 然 ...

  4. Ajax&Json笔记

    ## 今日内容     1. AJAX:     2. JSON # AJAX:     1. 概念: ASynchronous JavaScript And XML    异步的JavaScript ...

  5. 关于javaweb 项目 ssm框架 启动tomcat服务器同时启动一个socket服务

    1.创建监听类 import javax.servlet.ServletContext; import javax.servlet.ServletContextEvent; import javax. ...

  6. CSS完整

    CSS介绍 CSS(Cascading Style Sheet,层叠样式表)定义如何显示HTML元素. 当浏览器读到一个样式表,它就会按照这个样式表来对文档进行格式化(渲染). CSS语法 CSS实例 ...

  7. Dinic二分图匹配 || Luogu P3386

    题面:[模板]二分图匹配 思路:Dinic实现二分图匹配,要建一个超级源点(S)和超级汇点(T),分别定为N+M+1和N+M+2 然后S去和N中的数建正边和反边,正边权值为1,反边权值为0:M中的数去 ...

  8. jemter简单测试方式

    一.简介 Jmeter是一款优秀的开源测试工具, 是每个资深测试工程师,必须掌握的测试工具,熟练使用Jmeter能大大提高工作效率. **开源,他是一款开源的免费软件,使用它你不需要支付任何费用, * ...

  9. Zookeeper学习笔记(下)

    这是ZK学习笔记的下篇, 主要希望可以分享一些 ZK 的应用以及其应用原理 我本人的学习告一段落, 不过还遗留了一些ZK相关的任务开发和性能测试的任务, 留待以后完成之后再通过其他文章来进行分享了 Z ...

  10. Oracle RAC数据泵导出问题处理

    1. 设置导出文件路径 sqlplus / as sysdba SQL> alter session set container=spdb1pdb; SQL> create directo ...