Monday, April 29, 2024
 Popular · Latest · Hot · Upcoming
0
rated 0 times [  0] [ 0]  / answers: 1 / hits: 909  / 2 Years ago, tue, december 14, 2021, 1:41:24

I have inadvertently deleted the key that allows for updating of the system, and now when I try updating using sudo apt update I get the following terminal output


Get:1 file:/var/lib/preinstalled-pool focal InRelease
Ign:1 file:/var/lib/preinstalled-pool focal InRelease
Get:2 file:/var/lib/preinstalled-pool focal Release [3,949 B]
Get:2 file:/var/lib/preinstalled-pool focal Release [3,949 B]
Get:3 file:/var/lib/preinstalled-pool focal Release.gpg [455 B]
Get:3 file:/var/lib/preinstalled-pool focal Release.gpg [455 B]
Ign:3 file:/var/lib/preinstalled-pool focal Release.gpg
Hit:4 http://archive.ubuntu.com/ubuntu focal InRelease
Get:5 http://security.ubuntu.com/ubuntu focal-security InRelease [109 kB]
Hit:6 https://cloud.r-project.org/bin/linux/ubuntu focal-cran40/ InRelease
Hit:7 http://ppa.launchpad.net/webupd8team/y-ppa-manager/ubuntu focal InRelease
Get:8 http://archive.neon.kde.org/user focal InRelease [166 kB]
Get:9 http://archive.ubuntu.com/ubuntu focal-updates InRelease [114 kB]
Get:10 http://archive.ubuntu.com/ubuntu focal-updates/main amd64 Packages [844 kB]
Get:11 http://archive.ubuntu.com/ubuntu focal-updates/universe amd64 Packages [750 kB]
Reading package lists... Done
W: GPG error: file:/var/lib/preinstalled-pool focal Release: The following signatures couldn't be verified because the public key is not available: NO_PUBKEY E5231016A6508C17
E: The repository 'file:/var/lib/preinstalled-pool focal Release' is not signed.
N: Updating from such a repository can't be done securely, and is therefore disabled by default.
N: See apt-secure(8) manpage for repository creation and user configuration details.

How do I reinstall the public key, given that the error message says it is unavailable? FWIW I have an additional laptop with the same OS installed, so perhaps I could copy the key from this?


More From » updates

 Answers
6

This problem has now been solved thanks to user dbergstein on the KDE forum at https://forum.kde.org/viewtopic.php?f=309&t=170366.


The solution is quite simple:


apt-key export E5231016A6508C17 > key-data

on a machine that has the key installed, copy to the machine without the key, and then


sudo apt-key add key-data

where key-data is the name of the copied file.


[#1832] Thursday, December 16, 2021, 2 Years  [reply] [flag answer]
Only authorized users can answer the question. Please sign in first, or register a free account.
quivedge

Total Points: 223
Total Questions: 116
Total Answers: 124

Location: Slovenia
Member since Wed, Apr 6, 2022
2 Years ago
;