1. yum install python-pip
Loaded plugins: fastestmirror, langpacks
Loading mirror speeds from cached hostfile
* base: mirrors.163.com
* extras: mirrors.aliyun.com
* updates: mirrors.aliyun.com
No package python-pip available.
Error: Nothing to do
提示这种是没有安装
2. yum -y install epel-release
3. yum -y install python-pip
4. 升级pip
pip install --upgrade pip
5. 永久使用国内源安装
(1)mkdir ~/.pip
(2)cd ~/.pip
(3)vim ~/.pip/pip.conf
(4)文件填写内容
[global]
index-url = https://pypi.tuna.tsinghua.edu.cn/simple
[install]
trusted-host = https://pypi.tuna.tsinghua.edu.cn # trusted-host 此参数是为了避免麻烦,否则使用的时候可能会提示不受信任