GPG error: http://developer.download.nvidia.com/compute/cuda/repos/ubuntu1804/x86_64

Running on an x86 machine with Ubuntu 18.04 OS, I’m not managing to install any nvidia-drivers from the apt repo.

When I run sudo apt update I get the following errors:

Err:6 http://developer.download.nvidia.com/compute/cuda/repos/ubuntu1804/x86_64  InRelease                                       
  The following signatures couldn't be verified because the public key is not available: NO_PUBKEY A4B469963BF863CC
Reading package lists... Done                   
W: GPG error: http://developer.download.nvidia.com/compute/cuda/repos/ubuntu1804/x86_64  InRelease: The following signatures couldn't be verified because the public key is not available: NO_PUBKEY A4B469963BF863CC
E: The repository 'http://developer.download.nvidia.com/compute/cuda/repos/ubuntu1804/x86_64  InRelease' is no longer 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.

I get the exact same errors on 2 different machines. One of these machines was formatted today with a fresh Ubuntu image, and the other is an old machine which already has nvidia-driver-465 installed

I tried following the instructions in NVIDIA Driver Installation Quickstart Guide :: NVIDIA Tesla Documentation
to update the GPG key, but it made no difference.

I tried adding an alternate PPA repo - sudo add-apt-repository ppa:graphics-drivers.
This enabled me to install nvidia-driver-465, but then I met this old problem, which never got an answer from Nvidia.

I would very much appreciate anyone who could help, by either of the following options:

  1. Direct me to an apt repo which has a real nvidia-driver-465 (which doesn’t redirect to 470)
  2. Tell me how I can update the GPG key

Thanks!

System information:

me@driveu-us:~$ uname -a
Linux driveu-us 5.4.0-91-generic #102~18.04.1-Ubuntu SMP Thu Nov 11 14:46:36 UTC 2021 x86_64 x86_64 x86_64 GNU/Linux
1 Like

I’m getting the exact same error with apt-get calls as part of a dependency setup for a google colab notebook. Exact same code was working fine the last 3 days, so I’m assuming something happened on the repo side.

Issue reproducible by running the Step 0 code block in the Magenta getting started tutorial.

3 Likes

According to

Hi @erikwijmans
We are in the process of rotating our GPG public keys, there will be an announcement on the NVIDIA Developer blog very soon. Currently this has rolled out only for our ubuntu1604/x86_64 and fedora32/x86_64 repos, the rest will follow in a bit.

The new GPG keys for the CUDA repository

Please remove the old 7fa2af80 key

  • Debian-based distros:
    sudo apt-key del 7fa2af80
  • RPM-based distros:
    sudo rpm --erase gpg-pubkey-7fa2af80*

And enroll the new signing key (a cuda-keyring package is also provided)

  • Debian-based distros:

sudo apt-key adv --fetch-keys http://developer.download.nvidia.com/compute/cuda/repos/ubuntu1604/x86_64/3bf863cc.pub

  • RPM-based distros: please update .repo with package manager specific instructions (see blog post)
3 Likes

Thank you @pablete !!!

The following commands seem to have solved the issue for me (even though I’m running on 18.04, and not 16.04)

sudo apt-key del 7fa2af80
sudo apt-key adv --fetch-keys http://developer.download.nvidia.com/compute/cuda/repos/ubuntu1604/x86_64/3bf863cc.pub

I now have nvidia-driver-465 installed successfully :)

me@me:~$ nvidia-smi 
Thu Apr 28 18:04:21 2022       
+-----------------------------------------------------------------------------+
| NVIDIA-SMI 465.19.01    Driver Version: 465.19.01    CUDA Version: 11.3     |
|-------------------------------+----------------------+----------------------+
4 Likes

pablete is correct, the keys need to be updated full details here:
https://forums.developer.nvidia.com/t/notice-cuda-linux-repository-key-rotation/212771

No need to delete 7fa2af80 you can keep both until they stabilize.
If you deleted, you can pull it again with the sane command that pulled 3bf863cc,

How frequently these keys are rotated?

For a more generic solution I borrowed the code snippet from the official guide of nvidia and I got something like that in my Dockerfile using nvidia/cuda:11.6.0-runtime-ubuntu20.04 image:

RUN apt-get update -y && apt-get install curl -y \
      && distribution=$(. /etc/os-release;echo $ID$VERSION_ID) \
      && curl -fsSL https://nvidia.github.io/libnvidia-container/gpgkey | gpg --dearmor -o /usr/share/keyrings/nvidia-container-toolkit-keyring.gpg \
      && curl -s -L https://nvidia.github.io/libnvidia-container/$distribution/libnvidia-container.list | \
            sed 's#deb https://#deb [signed-by=/usr/share/keyrings/nvidia-container-toolkit-keyring.gpg] https://#g' | \
            tee /etc/apt/sources.list.d/nvidia-container-toolkit.list \
	&& apt-get -y update \
    && apt-get install -y --no-install-recommends \
       build-essential libopenblas-dev git python3-pip \
    && pip install --user -r /tmp/requirements.txt

I am following @nadeemm’s suggestion above.

On Ubuntu 20.04, x86_64, I’m running

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

Still getting the same error.

Any update on this, please?

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.