How to fix invalid key resource URL when adding a new ppa

All Gurus once were Newbies
Forum rules
There are no such things as "stupid" questions. However if you think your question is a bit stupid, then this is the right place for you to post it. Please stick to easy to-the-point questions that you feel people can answer fast. For long and complicated questions prefer the other forums within the support section.
Before you post please read how to get help
Post Reply
6825865
Level 1
Level 1
Posts: 1
Joined: Sat Jun 27, 2020 2:09 pm

How to fix invalid key resource URL when adding a new ppa

Post by 6825865 »

I'm attempting to add the lutris ppa using the following command:

sudo add-apt-repository ppa:lutris-team/lutris

which gives this output:

Code: Select all

You are about to add the following PPA:
 Stable releases for the Lutris client
 More info: https://launchpad.net/~lutris-team/+archive/ubuntu/lutris
Press Enter to continue or Ctrl+C to cancel

Executing: /tmp/apt-key-gpghome.Mo2y2aHEHd/gpg.1.sh --keyserver hkps://keyserver.ubuntu.com:443 --recv-keys 82D96E430A1F1C0F0502747E37B90EDD4E3EFAE4
gpg: key 37B90EDD4E3EFAE4: public key "Launchpad PPA for lutris" imported
gpg: Total number processed: 1
gpg:               imported: 1
gpg: invalid key resource URL '/tmp/apt-key-gpghome.Mo2y2aHEHd/home:ungoogled_chromium.asc.gpg'
gpg: keyblock resource '(null)': General error
gpg: key FCAE110B1118213C: 12 signatures not checked due to missing keys
gpg: key 7721F63BD38B4796: 18 signatures not checked due to missing keys
gpg: key 02456C79B2FD48BF: 1 signature not checked due to a missing key
gpg: key A6616109451BBBF2: 12 signatures not checked due to missing keys
gpg: key 3B4FE6ACC0B21F32: 3 signatures not checked due to missing keys
gpg: key D94AA3F0EFE21092: 3 signatures not checked due to missing keys
gpg: key C8CAB6595FDFF622: 2 signatures not checked due to missing keys
gpg: key 871920D1991BC93C: 1 signature not checked due to a missing key
gpg: Total number processed: 14
gpg:       skipped new keys: 14
There's a seemingly similar issue in this thread, which as of writing is unsolved:
viewtopic.php?f=18&t=322612&p=1834459&h ... e#p1834459

I've tried all the suggestions in that thread and got similar results, attempting to add the missing key to the key server doesn't seem to help.

I tried using the "software sources" gui that comes with mint by going to software sources>maintenance>add missing keys, the manager freezes whenever I do this.

I also wasn't sure why the invalid URL in my output contains "ungoogled_chromium" and I uninstalled ungoogled chromium just to make sure it wasn't interfering somehow, which was probably very stupid and didn't help.

There's another similar issue here, although with a user attempting to install a different program:
https://unix.stackexchange.com/question ... ux-mint-20

I've also tried downloading y-ppa to try to circumvent the issue somehow but was met with the same error. Also my version of mint is freshly updated to 19.3
sleeper12
Level 16
Level 16
Posts: 6133
Joined: Thu May 25, 2017 3:22 pm

Re: How to fix invalid key resource URL when adding a new ppa

Post by sleeper12 »

I don't know if it will help or not, but try:

Code: Select all

 sudo rm /etc/apt/trusted.gpg.d/home:ungoogled_chromium.asc 
User avatar
smurphos
Level 17
Level 17
Posts: 7285
Joined: Fri Sep 05, 2014 12:18 am
Location: Britisher
Contact:

Re: How to fix invalid key resource URL when adding a new ppa

Post by smurphos »

That should fix it.

If you want to reinstall ungoogled-chromium you'll need to add their signing key again. Unfortunately their instructions to do this (which are currently mirrored on the new Mint user guide for Mint 20 pending a revision being approved) cause this bug.

You can add the ungoogled-chromium signing key in a way that doesn't trigger this bug like this;

Mint 19.x

Code: Select all

wget -nv https://download.opensuse.org/repositories/home:ungoogled_chromium/Ubuntu_Bionic/Release.key -O /tmp/home:ungoogled_chromium.asc; sudo apt-key add /tmp/home:ungoogled_chromium.asc
Mint 20

Code: Select all

wget -nv https://download.opensuse.org/repositories/home:ungoogled_chromium/Ubuntu_Focal/Release.key -O /tmp/home:ungoogled_chromium.asc; sudo apt-key add /tmp/home:ungoogled_chromium.asc
https://github.com/ungoogled-software/u ... issues/153
https://github.com/linuxmint/mintsystem/issues/119
For custom Nemo actions, useful scripts for the Cinnamon desktop, and Cinnamox themes visit my Github pages.
User avatar
xenopeek
Level 25
Level 25
Posts: 25313
Joined: Wed Jul 06, 2011 3:58 am
Location: The Netherlands

Re: How to fix invalid key resource URL when adding a new ppa

Post by xenopeek »

The cause is OBS provided instructions that wrote the gpg keyfile directly to /etc/trusted.gpg.d/ but that doesn't work right for all APT tools. smurphos figured out the gpg keyfile should be written by apt-key to work right with all APT tools. Instructions here have been updated: https://linuxmint-user-guide.readthedoc ... d-chromium

If you added ungoogled chromium with the old instructions, running this should let you add PPAs again and list all keys in Software Sources—unless you have more OBS repositories for which you directly wrote a gpg keyfile in /etc/apt/trusted.gpg.d/ instead of using apt-key for that:

Code: Select all

sudo rm -v '/etc/apt/trusted.gpg.d/home:ungoogled_chromium.asc'
wget -nv https://download.opensuse.org/repositories/home:ungoogled_chromium/Ubuntu_Focal/Release.key -O - | sudo apt-key add -
apt update
Image
User avatar
nicolaasjan
Level 1
Level 1
Posts: 40
Joined: Sun Sep 23, 2012 2:26 pm
Location: The Netherlands

Re: How to fix invalid key resource URL when adding a new ppa

Post by nicolaasjan »

It seems OBS is working on the problem :)
https://github.com/openSUSE/software-o-o/issues/842
Linux Mint 19.3 Mate
omwani
Level 1
Level 1
Posts: 1
Joined: Mon Sep 07, 2020 12:05 am

Re: How to fix invalid key resource URL when adding a new ppa

Post by omwani »

there is similar problem while installing wine
Post Reply

Return to “Newbie Questions”