Error gpg keys in repository opensuse

Hello. Today, when I tried to update the system using zypper dup in the terminal, I got this error:

~ ❯❯❯ LANG=C sudo zypper dup
[sudo] password for root: 
Looking for gpg keys in repository Repositorio principal (NON-OSS).
  gpgkey=http://download.opensuse.org/tumbleweed/repo/non-oss/repodata/repomd.xml.key
Retrieving repository 'Repositorio principal (NON-OSS)' metadata -------------------[\]
Warning: Digest verification failed for file '50cb96cb78a1f33d94378d4a1aaf061bb129169eda3d40009fc3b25710c00fa4955674d7216f0653aed9c147a86a374a3d5cd49d08018b56688ca550c697a79d-appdata.xml.gz'
[/var/tmp/zypp.tmp/AP_0xx3DbjO/repodata/50cb96cb78a1f33d94378d4a1aaf061bb129169eda3d40009fc3b25710c00fa4955674d7216f0653aed9c147a86a374a3d5cd49d08018b56688ca550c697a79d-appdata.xml.gz]

  expected 50cb96cb78a1f33d94378d4a1aaf061bb129169eda3d40009fc3b25710c00fa4955674d7216f0653aed9c147a86a374a3d5cd49d08018b56688ca550c697a79d
  but got  a7d15507a23f1e237c14e56c95bb26ab47ef815ea64b163f6d6dff01470022118537bb175aba8069b40f756e2c4e6e82f965c2f3c6eb2270b7ac322a5e5b248a

Accepting packages with wrong checksums can lead to a corrupted system and in extreme cases even to a system compromise.

However if you made certain that the file with checksum 'a7d1..' is secure, correct
and should be used within this operation, enter the first 4 characters of the checksum
to unblock using this file on your own risk. Empty input will discard the file.

Unblock or discard? [a7d1/...? shows all options] (discard):

Simply wait some time and try later. This can happen when the mirror is mid sync.

2 Likes

Hmm, same error here, different repo. This is the first time ever for me that this happens. Tried zypper clean --all and then zypper dup, but still the same error.
Will follow @hui’s advice and wait some time.

1 Like

Hello. This is the first time this has happened to me too, and I didn’t know how to handle the situation properly, which is why I started this thread on the forum.

The repo is not syncing now:

The problem continues.

Your screenshot is from Leap…this thread is about Tumbleweed.
Your screenshot shows that the Leap 16.0 repo is properly synced. It does not sync every second or minute.

The issue persists in both distributions; I’ve checked it. Leap and TW.

1 Like

Same problem here. I’ve had it before and it’s always gone away after a few hours, but eight + hours is unusual.

See here, maybe that helps:

Hello. The problem with the signatures persists. The link you provided states that the GPG public key signatures were modified on 27 August.
Best regards

Add -vv global option to zypper dup invocation , see over which mirror it trips

sudo zypper -vv dup
1 Like

Hello. The mirror site it takes me to is the one in Lisboa (Portugal).
http://ftp.rnl.tecnico.ulisboa.pt/pub/opensuse/tumb

Try to append ?AVOID_COUNTRY=pt to the baseurl of the repo, eg.

http://download.opensuse.org/tumbleweed/repo/non-oss/?AVOID_COUNTRY=pt
1 Like

Or block the domain by adding the following to /etc/hosts

0.0.0.0 ftp.rnl.tecnico.ulisboa.pt

Hello. I’ve tried simulating a fresh system installation using YaST, and when I add the repositories, I get the same error with the GPG key

YaST probably automatically probe the url and does not support the ?AVOID_COUNTRY parameter.
Try add with zypper, eg.

sudo zypper addrepo -f https://download.opensuse.org/tumbleweed/repo/non-oss/?AVOID_COUNTRY=pt

And, it’s not an error with GPG key.
It’s erroring when verifying the checksum of
http://download.opensuse.org/tumbleweed/repo/non-oss/repodata/50cb96cb78a1f33d94378d4a1aaf061bb129169eda3d40009fc3b25710c00fa4955674d7216f0653aed9c147a86a374a3d5cd49d08018b56688ca550c697a79d-appdata.xml.gz

1 Like

I forgot the alias in the zypper command

sudo zypper addrepo -f https://download.opensuse.org/tumbleweed/repo/non-oss/?AVOID_COUNTRY=pt non-oss-avoid-pt
1 Like

You can use the offline image, don’t select online repositories during installation, modify the repos after the installation is finished.

I also found a thread about access the terminal during installation, from there maybe you can add repo with zypper? Just guess, not tried. Better to use offline image.

To resolve the problem, I had to modify all the entries in the “*.repo” files in “/etc/zypp/repos.d/”. Specifically, I changed the line “baseurl=https://cdn.opensuse.org…” to “baseurl=https://download.opensuse.org/…”. Then I ran zypper ref and it worked. I’m not sure if this is the correct way to do it, or if the repositories can be modified with a command.

1 Like

It no longer gives an error when updating. Fixed

1 Like