docker换源以后,就报了这个错。
换源前:
deb http://deb.debian.org/debian stretch main contrib non-free
换源后:
deb https://mirrors.tuna.tsinghua.edu.cn/ubuntu/ jammy main restricted universe multiverse
deb https://mirrors.tuna.tsinghua.edu.cn/ubuntu/ jammy-updates main restricted universe multiverse
deb https://mirrors.tuna.tsinghua.edu.cn/ubuntu/ jammy-backports main restricted universe multiverse
deb https://mirrors.tuna.tsinghua.edu.cn/ubuntu/ jammy-security main restricted universe multiverse
解决方法:把软件源里的https改成http
vi /etc/apt/sources.list
apt-get update
deb http://mirrors.tuna.tsinghua.edu.cn/ubuntu/ jammy main restricted universe multiverse
deb http://mirrors.tuna.tsinghua.edu.cn/ubuntu/ jammy-updates main restricted universe multiverse
deb http://mirrors.tuna.tsinghua.edu.cn/ubuntu/ jammy-backports main restricted universe multiverse
deb http://mirrors.tuna.tsinghua.edu.cn/ubuntu/ jammy-security main restricted universe multiverse
报错1:
W: GPG error: http://mirrors.tuna.tsinghua.edu.cn/ubuntu jammy-security InRelease: The following signatures Couldn't be verified because the public key is not available: NO_PUBKEY 871920D1991BC93D
W: The repository 'http://mirrors.tuna.tsinghua.edu.cn/ubuntu jammy-security InRelease' is not signed.
N: Data from such a repository can't be authenticated and is therefore potentially dangerous to use.
N: See apt-secure(8) manpage for repository creation and user configuration details.
root@syzkaller:~# apt-key adv --recv-keys --keyserver keyserver.ubuntu.com 871920D1991BC93D
解决1:
apt-key adv --recv-keys --keyserver keyserver.ubuntu.com 871920D1991BC93C(上面显示的公钥)
报错2:
Failed to start the dirmngr '/usr/bin/dirmngr': No such file or directory
解决2:
sudo apt-get update -y
sudo apt-get install -y dirmngr
折腾2小时终于搞定了。
扩展:
版权声明:本文内容由互联网用户自发贡献,该文观点与技术仅代表作者本人。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌侵权/违法违规的内容, 请发送邮件至 dio@foxmail.com 举报,一经查实,本站将立刻删除。