Something went wrong while updating the cache of APT (due to SURY)

:uk:/:us: What to do if you have an error while updating the repo ?

I just had an error while trying to update my server :

[multiple sources listed here]
W: Some index files failed to download. They have been ignored, or old ones used instead.

W: Failed to fetch https://packages.sury.org/php/dists/buster/InRelease The following signatures were invalid: EXPKEYSIG B188E2B695BD4743 DEB.SURY.ORG Automatic Signing Key

W: An error occurred during the signature verification. The repository is not updated and the previous index files will be used. GPG error: https://packages.sury.org/php buster InRelease: The following signatures were invalid: EXPKEYSIG B188E2B695BD4743 DEB.SURY.ORG Automatic Signing Key 

I then found this issue in the sury bug tracker : Expired Debian key issue · Issue #1575 · oerdnj/deb.sury.org · GitHub
With this nice one line fix : apt-key del 95BD4743; wget -nv -O - "https://packages.sury.org/php/apt.gpg" | apt-key add -
(On my server, I had to run this adaptation : sudo apt-key del 95BD4743; wget -nv -O - "https://packages.sury.org/php/apt.gpg" | sudo apt-key add -

Hopping it will help :smiley:


:fr:Que faire en cas d’erreur lors de l’update des paquets ?

Je viens d’avoir cette erreur en essayant de mettre à jour mon serveur :

[plusieurs fichier source listés ici]
W: Some index files failed to download. They have been ignored, or old ones used instead.

W: Failed to fetch https://packages.sury.org/php/dists/buster/InRelease The following signatures were invalid: EXPKEYSIG B188E2B695BD4743 DEB.SURY.ORG Automatic Signing Key

W: An error occurred during the signature verification. The repository is not updated and the previous index files will be used. GPG error: https://packages.sury.org/php buster InRelease: The following signatures were invalid: EXPKEYSIG B188E2B695BD4743 DEB.SURY.ORG Automatic Signing Key 

J’ai ensuite trouvé ce ticket sur le bug tracker de sury : Expired Debian key issue · Issue #1575 · oerdnj/deb.sury.org · GitHub
Avec ce joli petit fix en une commande : apt-key del 95BD4743; wget -nv -O - "https://packages.sury.org/php/apt.gpg" | apt-key add -
(Sur mon serveur j’ai du l’exécuter comme ça : sudo apt-key del 95BD4743; wget -nv -O - "https://packages.sury.org/php/apt.gpg" | sudo apt-key add -

En espérant que ça aide :smiley:

24 Likes

Empty post to mark it solved.

2 Likes

I had the same issue, applied the fix offered and not error anymore.

Many thanks!

On a side note, I was not doing anything on my server, just daily updates via ssh. Is this a widely spread issue?

1 Like

:us: :uk: The https://packages.sury.org/ repo is not enabled on YunoHost by default, most likely some YunoHost app you both installed added it as a dependency. If you can figure out which app it was you should file an issue asking them to push an update adding the new key.


:fr: Le dépot de paquets https://packages.sury.org/ n’est pas activé par defaut sur Yunohost, il semble que une appli que vous avez installé a activé ce dépot. Vous devrez signaler ce problème sur le GitHub de l’application, si vous pouvez la retrouver.

thank you! worked well for me too. i had to do

sudo sudo apt-key del 95BD4743; wget -nv -O - "https://packages.sury.org/php/apt.gpg" | sudo apt-key add -

Not sure what app installed this sury repository though.

As far as I remember, this repo was needed for Yunohost on stretch. I suspect it is no more useful on Buster.

I commented it and did my upgrade. Seems to work.

I need be sure, Can we remove this repo with buster ?

No you shouldn’t, many apps probably rely on it, and once you have some packages installed from sury it’s quite hard to get back to a “vanilla-debian only” because of the way apt / .deb works. It’s no big deal to have sury enabled nowadays.

2 Likes

Ok, so does I have a risk to brake something if I comment the repo ? I need first be sure there’s no php packages from this repo ? Sorry, I haven’t read well your post. So I can still use the sury repo, thanks.

Strictly speaking it won’t break anything to comment the repo, it’s “just” that you’re likely to not receive any upgrade for the php packages (at best) or that once Debian catches-up with the versions (could take years I guess), it makes everything explode (at worst)

2 Likes

Had the same issue, it appears on March 18th on my VPS. Found the same subject on Git, applied the solution and no issue since. :+1:

1 Like

I applied the fix on the GPG key. I updated and…

N: Skipping acquire of configured file 'main/binary-armel/Packages' as repository 'https://packages.sury.org/php buster InRelease' doesn't support architecture 'armel'

I’m running a armv5tel (uname) device. I fear the end of a long journey with Yunohost on this device…

I get it too:

Something went wrong while updating the cache of APT (Debian's package manager). Here is a dump of the sources.list lines, which might help identify problematic lines:
sources.list:deb http://asi-fs-n.contabo.net/debian buster main non-free contrib
sources.list:deb-src http://asi-fs-n.contabo.net/debian buster main non-free contrib
sources.list:deb http://security.debian.org/debian-security buster/updates main contrib non-free
sources.list:deb-src http://security.debian.org/debian-security buster/updates main contrib non-free
sources.list:deb http://asi-fs-n.contabo.net/debian buster-updates main contrib non-free
sources.list:deb-src http://asi-fs-n.contabo.net/debian buster-updates main contrib non-free
sources.list.d/mobilizon.list:deb http://packages.erlang-solutions.com/debian buster contrib
sources.list.d/crystal.list:deb https://dl.bintray.com/crystal/deb all stable
sources.list.d/yunohost.list:deb https://forge.yunohost.org/debian/ buster stable
sources.list.d/invidious.list:deb https://dl.bintray.com/crystal/deb all stable
sources.list.d/onlyoffice.list:deb http://download.onlyoffice.com/repo/debian squeeze main
sources.list.d/webmin.list:deb http://download.webmin.com/download/repository sarge contrib

But no signature error.

Même problème, résolu par le fix proposé ! (bon j’ai eu une tonne de mises à jour PHP ensuite mais tout s’est bien passé).

Merci !

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