21

I get errors while make sudo apt update

➜  ~ sudo apt-get update
Err:1 https://linux-clients.seafile.com/seadrive-deb/focal stable InRelease
  The following signatures couldn't be verified because the public key is not available: NO_PUBKEY 2B844307BE7E9E8C
Err:14 http://ppa.launchpad.net/mc3man/xerus-media/ubuntu focal Release
  404  Not Found [IP: 91.189.95.85 80]
Err:15 http://ppa.launchpad.net/pypa/ppa/ubuntu focal Release
  404  Not Found [IP: 91.189.95.85 80]
Err:8 https://developer.download.nvidia.com/compute/cuda/repos/ubuntu2004/x86_64  InRelease
  The following signatures couldn't be verified because the public key is not available: NO_PUBKEY A4B469963BF863CC

Runing though 80 port - no data:

➜  ~ sudo apt-key adv --keyserver hkp://keyserver.ubuntu.com:80 --recv-keys 2B844307BE7E9E8C
Executing: /tmp/apt-key-gpghome.dThi8vDgCQ/gpg.1.sh --keyserver hkp://keyserver.ubuntu.com:80 --recv-keys 2B844307BE7E9E8C
gpg: keyserver receive failed: No data

what else can I do to solve this problem?

!!!solved Thanks!!!

Yuriy Simonov
  • 311
  • 1
  • 2
  • 4
  • Did you already run `sudo wget https://linux-clients.seafile.com/seafile.asc -O /usr/share/keyrings/seafile-keyring.asc` and is the repository listed as `deb [arch=amd64 signed-by=/usr/share/keyrings/seafile-keyring.asc] https://linux-clients.seafile.com/seafile-deb/focal/ stable main'` in your `/etc/apt/sources.list.d/seafile.list` file? – mchid May 11 '22 at 19:00
  • Also, do you get the same error for Nvidia? – mchid May 11 '22 at 19:01
  • sudo wget https://linux-clients.seafile.com/seafile.asc -O /usr/share/keyrings/seafile-keyring.asc solve problem with NO_PUBKEY 2B844307BE7E9E8C – Yuriy Simonov May 12 '22 at 07:24
  • Looks like there are no this row. Should I add one? ``` ➜ ~ cat /etc/apt/sources.list.d/seafile.list deb http://deb.seadrive.org stretch main ``` – Yuriy Simonov May 12 '22 at 07:25
  • If the first command fixed the problem, you can skip the second command and leave the line as it is. Answer provided below. Don't forget to upvote answers if they work for you. – mchid May 12 '22 at 07:53

4 Answers4

20

Looks like NVIDIA has updated its signing keys as of April 27, 2022. You can follow these instructions to update your system with the new ones.


The recommended method is to use a helper package to automatically install the keys. To install the helper package (and the keys), run the following commands:

wget https://developer.download.nvidia.com/compute/cuda/repos/ubuntu2004/x86_64/cuda-keyring_1.0-1_all.deb
sudo dpkg -i cuda-keyring_1.0-1_all.deb

Alternatively, you can install the key manually by using the following commands (not the recommended method):

sudo apt-key adv --fetch-keys https://developer.download.nvidia.com/compute/cuda/repos/ubuntu2004/x86_64/3bf863cc.pub
mchid
  • 42,315
  • 7
  • 94
  • 147
Epimetheus
  • 484
  • 2
  • 13
  • it's help with Nvidia public key! Thanks!!! – Yuriy Simonov May 12 '22 at 07:35
  • I needed to run these as well, but finally worked! `sed -i '/developer\.download\.nvidia\.com\/compute\/cuda\/repos/d' /etc/apt/sources.list.d/* && sed -i '/developer\.download\.nvidia\.com\/compute\/machine-learning\/repos/d' /etc/apt/sources.list.d/*` – alan.elkin Nov 28 '22 at 15:56
7

apt-key now seems to be deprecated, I have created a script that will detect and get the missing keys, you can get it here.

#!/bin/sh -e
tmp="$(mktemp)"
sudo apt-get update 2>&1 | sed -En 's/.*NO_PUBKEY ([[:xdigit:]]+).*/\1/p' | sort -u > "${tmp}"
cat "${tmp}" | xargs sudo gpg --keyserver "hkps://keyserver.ubuntu.com:443" --recv-keys  # to /usr/share/keyrings/*
cat "${tmp}" | xargs -L 1 sh -c 'sudo gpg --yes --output "/etc/apt/trusted.gpg.d/$1.gpg" --export "$1"' sh  # to /etc/apt/trusted.gpg.d/*
rm "${tmp}"
0000matteo0000
  • 141
  • 1
  • 2
2

In addition to the other answer with Nvidia instructions, run the following commands to fix your seafile repository.

If the first command fixes the problem, you can skip the second command.

sudo wget https://linux-clients.seafile.com/seafile.asc -O /usr/share/keyrings/seafile-keyring.asc
sudo bash -c "echo 'deb [arch=amd64 signed-by=/usr/share/keyrings/seafile-keyring.asc] https://linux-clients.seafile.com/seafile-deb/focal/ stable main' > /etc/apt/sources.list.d/seafile.list"

The official instructions can be found here.

mchid
  • 42,315
  • 7
  • 94
  • 147
0

Just run

$ sudo apt-key adv --keyserver keyserver.ubuntu.com --recv-keys A4B469963BF863CC

This will download the missing key from the keyserver repository.