ubuntu系统安装pip命令报错Failed to fetch http://xxxxxxx 404 Not found [IP: xx.xx.xx.xx]

本文讲述了在Ubuntu系统中使用`sudoaptinstallpython3-pip`时遇到的404错误,解决方法是先执行`sudoapt-getupdate`更新软件包信息,然后重新安装pip,最后通过`pip3--version`验证安装成功。
摘要由CSDN通过智能技术生成
问题描述

在ubuntu系统中使用如下命令安装pip:

sudo apt install python3-pip

安装过程中出现如下报错:

E: Failed to fetch http://security.ubuntu.com/ubuntu/pool/main/l/linux/linux-libc-dev_5.4.0-153.170_amd64.deb  404  Not Found [IP: xx.xx.xx.xx]
E: Failed to fetch http://security.ubuntu.com/ubuntu/pool/universe/p/python-pip/python-pip-whl_20.0.2-5ubuntu1.9_all.deb  404  Not Found [IP: xx.xx.xx.xx]
E: Failed to fetch http://security.ubuntu.com/ubuntu/pool/universe/p/python-pip/python3-pip_20.0.2-5ubuntu1.9_all.deb  404  Not Found [IP: xx.xx.xx.xx]
E: Unable to fetch some archives, maybe run apt-get update or try with --fix-missing?
解决方案

执行如下命令更新系统软件包信息:

sudo apt-get update

上述命令执行完之后,再执行pip安装命令,没有报错,正常执行完成。

安装验证

使用如下命令验证pip命令是否安装成功:

pip3 --version

若能够正常输出pip命令版本,则说明安装成功。

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值