Cannot install pip from get-pip.py
我正在未经root许可的远程Linux系统上工作。 我想在本地安装python和pip。 我已经成功安装了python,但是在pip上失败了。 我使用的命令如下:
1 2 | wget https://bootstrap.pypa.io/get-pip.py python get-pip.py --user |
下载成功,但是在运行第二条命令时,我收到了错误消息:
1 2 3 4 5 6 | pip is configured with locations that require TLS/SSL, however the ssl module in Python is not available. Collecting pip Could not fetch URL https://pypi.python.org/simple/pip/: There was a problem confirming the ssl certificate: Can't connect to HTTPS URL because the SSL module is not available. - skipping Could not find a version that satisfies the requirement pip (from versions: ) No matching distribution found for pip |
我也试过
1 | python get-pip.py |
但是错误是相同的。
我的命令出了什么问题?
谢谢大家的帮助!!!
在这种情况下,您会发现也不能
解决方案是:
安装openssl
配置源代码
然后打开
1 2 3 4 | #SSL=/usr/local/ssl #_ssl _ssl.c \ # -DUSE_SSL -I$(SSL)/include -I$(SSL)/include/openssl \ # -L$(SSL)/lib -lssl -lcrypto |