sudo apt update出错 ,

文章来源:https://www.wandouip.com/t5i364432/

为了处理最近一起安全事件,旧密钥已被撤销。所以在执行apt-get update 时会提示密钥错误,更换密钥即可。
新的密钥和旧的密钥如下:

old key: 421C365BD9FF1F717815A3895523BAEEB01FA116
new key: C1CF6E31E6BADE8868B172B4F42ED6FBAB17C654

解决方法

首先要删除旧的密钥:

16.04以后的版本:

 sudo apt-key del 421C365BD9FF1F717815A3895523BAEEB01FA116

15.10:

sudo apt-key del B01FA116
然后添加新的密钥:
sudo -E apt-key adv --keyserver ‘hkp://keyserver.ubuntu.com:80‘ --recv-key C1CF6E31E6BADE8868B172B4F42ED6FBAB17C654

最后再运行sudo apt update就行了。

参考:https://answers.ros.org/question/325039/apt-update-fails-cannot-install-pkgs-key-not-working/

原文地址:https://www.cnblogs.com/knightningwing/p/11457936.html

时间: 2024-08-24 09:47:29

sudo apt update出错 ,的相关文章

Ubuntu用sudo apt-get update出错:E: Problem executing scripts APT::Update::Post-Invoke-Success

Ubuntu用sudo apt-get update出错: E: Problem executing scripts APT::Update::Post-Invoke-Success 'if /usr/bin/test -w /var/cache/app-info -a -e /usr/bin/appstreamcli; then appstreamcli refresh > /dev/null; fi'   E: Sub-process returned an error code 解决方法:

ubuntu18.04 sudo apt-get update出错

[原因]sources.list中源不正确.修改其中的版本为对应版本即可.如把xenial改为bionic. 版本代号如下: 18.04:bionic:17.10:artful:16.04:xenial:14.04:trusty. [操作]sudo gedit /etc/apt/sources.list 替换对应版本后保存即可.再次sudo apt-get update,一切顺利. [参考] Ubuntu 源使用帮助 原文地址:https://www.cnblogs.com/xixixing/p

sudo apt-get update:Could not get lock /var/lib/apt/lists/lock解决办法

今天更新时候出现了点小问题,一开始更新到一半,我嫌速度慢,就取消掉了. 更新了sources.list之后再执行sudo apt-get update 提示我出错了 E: Could not get lock /var/lib/apt/lists/lock - open (11 Resource temporarily unavailable) E: Unable to lock the list directory 在网上搜索到的解决方案──“将/var/lib/apt/list/lock删除

ubuntu sudo apt-get update 失败 解决方法

sudo apt-get update 报了一堆错误: Err http://cn.archive.ubuntu.com trusty InRelease Err http://cn.archive.ubuntu.com trusty-updates InRelease Err http://cn.archive.ubuntu.com trusty-backports InRelease Err http://cn.archive.ubuntu.com trusty Release.gpg W:

Ubuntu 16.04出现:Problem executing scripts APT::Update::Post-Invoke-Success 'if /usr/bin/test -w /var/cache/app-info -a -e /usr/bin/appstreamcli; then appstreamcli refresh > /dev/null; fi'

错误: Reading package lists... Done E: Problem executing scripts APT::Update::Post-Invoke-Success 'if /usr/bin/test -w /var/cache/app-info -a -e /usr/bin/appstreamcli; then appstreamcli refresh > /dev/null; fi' E: Sub-process returned an error code 在运行

sudo apt-get update 无法获得锁

问题: 更新资源sudo apt-get update时遇到 E: 无法获得锁 /var/lib/apt/lists/lock - open (11: 资源暂时不可用) E: 无法对目录 /var/lib/apt/lists/ 加锁 解决办法: (1)sudo rm /var/lib/apt/lists/lock (2) ps aux      #列出当前进程列表 找到 apt-get 那个被lock住的进程记下PID sudo kill PID 即可

sudo apt-get update 不了

Ubuntu 11.04 (Natty) 已经停止支持,但可以使用old-releases源了,先备份源列表文件: sudo cp /etc/apt/sources.list /etc/apt/sources.list.backup sudo gedit /etc/apt/sources.list 把里面的内容替换为以下内容: deb http://old-releases.ubuntu.com/ubuntu/ natty main restricted universe multiverse 

ubuntu14.04中sudo apt-get update很慢的解决方法

1.打开终端,进入目录:  cd /etc/apt 2.备份一下原来的source文件:sudo cp sources.list sources.list.bak 3.打开source文件,sudo gedit /etc/apt/sources.list 将内容替换为: # deb cdrom:[Ubuntu 16.04 LTS _Xenial Xerus_ - Release amd64 (20160420.1)]/ xenial main restricted deb-src http://

sudo apt-get update 去除设置的代理

今天想装个软件(wine),使用 sudo apt-get update 命令时,发现给出很多Ign 语句,总出现 Connecting to proxy.http://10.0.126.1:13128 的字样,发现这个代理是已经废弃掉的.接着想去取消使用该代理: 1. 查看/etc/apt/apt.conf,发现存在: http_proxy="http://10.0.126.1:13128/" https_proxy="https://10.0.126.1:13128/&q