第一步:添加源
sudo vim /etc/apt/sources.list
deb http://cn.archive.ubuntu.com/ubuntu bionic main multiverse restricted universe
deb http://cn.archive.ubuntu.com/ubuntu bionic-updates main multiverse restricted universe
deb http://cn.archive.ubuntu.com/ubuntu bionic-security main multiverse restricted universe
deb http://cn.archive.ubuntu.com/ubuntu bionic-proposed main multiverse restricted universe
第二步:更新源
sudo apt-get update
- 错误
W: GPG 错误:http://cn.archive.ubuntu.com/ubuntu bionic InRelease: 由于没有公钥,无法验证下列签名: NO_PUBKEY 3B4FE6ACC0B21F32
W: 仓库 “http://cn.archive.ubuntu.com/ubuntu bionic InRelease” 没有数字签名。
N: 无法认证来自该源的数据,所以使用它会带来潜在风险。
N: 参见 apt-secure(8) 手册以了解仓库创建和用户配置方面的细节。
W: GPG 错误:http://cn.archive.ubuntu.com/ubuntu bionic-updates InRelease: 由于没有公钥,无法验证下列签名: NO_PUBKEY 3B4FE6ACC0B21F32
W: 仓库 “http://cn.archive.ubuntu.com/ubuntu bionic-updates InRelease” 没有数字签名。
N: 无法认证来自该源的数据,所以使用它会带来潜在风险。
N: 参见 apt-secure(8) 手册以了解仓库创建和用户配置方面的细节。
W: GPG 错误:http://cn.archive.ubuntu.com/ubuntu bionic-security InRelease: 由于没有公钥,无法验证下列签名: NO_PUBKEY 3B4FE6ACC0B21F32
W: 仓库 “http://cn.archive.ubuntu.com/ubuntu bionic-security InRelease” 没有数字签名。
N: 无法认证来自该源的数据,所以使用它会带来潜在风险。
N: 参见 apt-secure(8) 手册以了解仓库创建和用户配置方面的细节。
W: GPG 错误:http://cn.archive.ubuntu.com/ubuntu bionic-proposed InRelease: 由于没有公钥,无法验证下列签名: NO_PUBKEY 3B4FE6ACC0B21F32
W: 仓库 “http://cn.archive.ubuntu.com/ubuntu bionic-proposed InRelease” 没有数字签名。
N: 无法认证来自该源的数据,所以使用它会带来潜在风险。
N: 参见 apt-secure(8) 手册以了解仓库创建和用户配置方面的细节。
- 解决
sudo apt-key adv --recv-keys --keyserver keyserver.ubuntu.com 3B4FE6ACC0B21F32
- 错误
Executing: /tmp/apt-key-gpghome.zRYIywunjd/gpg.1.sh --recv-keys --keyserver keyserver.ubuntu.com 3B4FE6ACC0B21F32
gpg: failed to start the dirmngr '/usr/bin/dirmngr': 没有那个文件或目录
gpg: connecting dirmngr at '/tmp/apt-key-gpghome.zRYIywunjd/S.dirmngr' failed: 没有那个文件或目录
gpg: keyserver receive failed: No dirmngr
- 解决
sudo apt install dirmngr
第三步:升级
sudo add-apt-repository ppa:jonathonf/python-3.6
- 错误
Traceback (most recent call last):
File "/usr/bin/add-apt-repository", line 107, in <module>
sp = SoftwareProperties(options=options)
File "/usr/lib/python3/dist-packages/softwareproperties/SoftwareProperties.py", line 117, in __init__
self.reload_sourceslist()
File "/usr/lib/python3/dist-packages/softwareproperties/SoftwareProperties.py", line 612, in reload_sourceslist
self.distro.get_sources(self.sourceslist)
File "/usr/lib/python3/dist-packages/aptsources/distro.py", line 93, in get_sources
(self.id, self.codename))
aptsources.distro.NoDistroTemplateException: Error: could not find a distribution template for Deepin/stable
- 解决
sudo vim /etc/apt/sources.list
deb http://ppa.launchpad.net/yubico/stable/ubuntu cosmic main
deb-src http://ppa.launchpad.net/yubico/stable/ubuntu cosmic main
sudo apt-get update
- 错误
正在读取软件包列表... 完成
W: GPG 错误:http://ppa.launchpad.net/yubico/stable/ubuntu cosmic InRelease: 由于没有公钥,无法验证下列签名: NO_PUBKEY 43D5C49532CBA1A9
W: 仓库 “http://ppa.launchpad.net/yubico/stable/ubuntu cosmic InRelease” 没有数字签名。
N: 无法认证来自该源的数据,所以使用它会带来潜在风险。
N: 参见 apt-secure(8) 手册以了解仓库创建和用户配置方面的细节。
- 解决
sudo apt-key adv --recv-keys --keyserver keyserver.ubuntu.com 43D5C49532CBA1A9