Ubuntu安装软件时出现错误:Reading package lists... Error!

具体错误如下:

Reading package lists... Error!
E: Unable to parse package file /var/lib/apt/lists/cn.archive.ubuntu.com_ubuntu_dists_trusty_restricted_i18n_Translation-en%5fUS (1)
E: The package lists or status file could not be parsed or opened.

错误原因是更新列表时没有进行完全,需要将已更新文件删除,

再重新更新一下。

sudo rm /var/lib/apt/lists/* -vf

删除文件需要root权限,删除好之后再更新与源

sudo apt-get update

更新好之后就可以用apt来安装软件了。

root@sw:~/Serve/vscode# ./uninstall.sh Reading package lists... Done Building dependency tree... Done Reading state information... Done No apt package "code", but there is a snap with that name. Try "snap install code" E: Unable to locate package code Reading package lists... Done Building dependency tree... Done Reading state information... Done 0 upgraded, 0 newly installed, 0 to remove and 26 not upgraded. Hit:1 http://mirrors.cloud.aliyuncs.com/ubuntu jammy InRelease Hit:2 http://mirrors.cloud.aliyuncs.com/ubuntu jammy-updates InRelease Hit:3 http://mirrors.cloud.aliyuncs.com/ubuntu jammy-backports InRelease Hit:4 http://mirrors.cloud.aliyuncs.com/ubuntu jammy-security InRelease Ign:5 https://download.docker.com/linux/ubuntu jammy InRelease Ign:5 https://download.docker.com/linux/ubuntu jammy InRelease Hit:6 https://packages.emqx.com/emqx/emqx/ubuntu jammy InRelease Ign:5 https://download.docker.com/linux/ubuntu jammy InRelease Err:5 https://download.docker.com/linux/ubuntu jammy InRelease Could not handshake: Error in the pull function. [IP: 3.170.229.54 443] Reading package lists... Done Building dependency tree... Done Reading state information... Done 26 packages can be upgraded. Run 'apt list --upgradable' to see them. W: Failed to fetch https://download.docker.com/linux/ubuntu/dists/jammy/InRelease Could not handshake: Error in the pull function. [IP: 3.170.229.54 443] W: Some index files failed to download. They have been ignored, or old ones used instead. Warning: apt-key is deprecated. Manage keyring files in trusted.gpg.d instead (see apt-key(8)). 验证结果: [警告] 检测到残留二进制 [成功] 无运行中进程
05-13
sudo apt-get install -y docker-ce docker-ce-cli containerd.io docker-buildx-plugin docker-compose-plugin Ign:1 https://download.docker.com/linux/ubuntu jammy InRelease Hit:2 http://security.ubuntu.com/ubuntu jammy-security InRelease Hit:3 http://mirrors.tuna.tsinghua.edu.cn/ubuntu jammy InRelease Hit:4 http://mirrors.tuna.tsinghua.edu.cn/ubuntu jammy-updates InRelease Hit:5 http://mirrors.tuna.tsinghua.edu.cn/ubuntu jammy-backports InRelease Ign:1 https://download.docker.com/linux/ubuntu jammy InRelease Ign:1 https://download.docker.com/linux/ubuntu jammy InRelease Err:1 https://download.docker.com/linux/ubuntu jammy InRelease Could not handshake: Error in the pull function. [IP: 2600:9000:2864:1400:3:db06:4200:93a1 443] Reading package lists... Done W: Failed to fetch https://download.docker.com/linux/ubuntu/dists/jammy/InRelease Could not handshake: Error in the pull function. [IP: 2600:9000:2864:1400:3:db06:4200:93a1 443] W: Some index files failed to download. They have been ignored, or old ones used instead. Reading package lists... Done Building dependency tree... Done Reading state information... Done Package docker-ce is not available, but is referred to by another package. This may mean that the package is missing, has been obsoleted, or is only available from another source E: Package 'docker-ce' has no installation candidate E: Unable to locate package docker-ce-cli E: Unable to locate package containerd.io E: Couldn't find any package by glob 'containerd.io' E: Couldn't find any package by regex 'containerd.io' E: Unable to locate package docker-buildx-plugin E: Unable to locate package docker-compose-plugin
最新发布
08-27
评论
成就一亿技术人!
拼手气红包6.0元
还能输入1000个字符
 
红包 添加红包
表情包 插入表情
 条评论被折叠 查看
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包

打赏作者

WangLanguager

您的鼓励是对我最大的支持

¥1 ¥2 ¥4 ¥6 ¥10 ¥20
扫码支付:¥1
获取中
扫码支付

您的余额不足,请更换扫码支付或充值

打赏作者

实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

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

余额充值