ROS Resources: Documentation | Support | Discussion Forum | Index | Service Status | ros @ Robotics Stack Exchange
Ask Your Question

what's the key-id in trusted.gpg.d?

asked 2021-09-23 21:03:40 -0500

yang gravatar image

Hi! I'm a newbie just following "" have some test.

But there's a warning in shell. [OS: ubuntu 21.04]

[1.3 Set up your keys]

daneil @vpc:~$ curl -s | sudo apt-key add -
Warning: apt-key is deprecated. Manage keyring files in trusted.gpg.d instead (see apt-key(8)).
gpg: no valid OpenPGP data found.

After a few google later. I guess It should be written like this:

$ curl -s | sudo gpg --no-default-keyring --keyring /etc/apt/trusted.gpg.d/{key-id}.gpg --import -

My question is What's the {key-id}? Thanks!


edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted

answered 2021-09-25 10:31:34 -0500

Mike Scheutzow gravatar image

I installed noetic using the apt-key add - method, and it worked fine. I don't remember if I got the warning or not (note that it is only a warning telling you something is going to stop working in the future, it is not an error.)

Looking at the man pages for gpg and apt-key, {key-id} appears to be a name you make up to remind yourself what this key is for. For example, you could use ros.

edit flag offensive delete link more


I tried the curl command provided in the above question and got an issue.

gpg: keyserver receive failed: End of file
W: The key(s) in the keyring /etc/apt/trusted.gpg.d/ros.gpg are ignored as the file has an unsupported filetype.

Any solution for this ?

ros_user_ak gravatar image ros_user_ak  ( 2022-05-19 02:21:27 -0500 )edit

That first line looks like the error from using apt-key, not curl. Also, before running the command you should remove /etc/apt/trusted.gpg.d/ros.gpg if you already created a corrupt file there.

Mike Scheutzow gravatar image Mike Scheutzow  ( 2022-05-19 08:48:02 -0500 )edit

Question Tools



Asked: 2021-09-23 21:03:40 -0500

Seen: 760 times

Last updated: Sep 25 '21