Fedora Core (Linux) tip: manually installing RPMs using Yum

Tags: 

Here's a little tip I came across today while attempting to manually install software using Yum.

One of the the really cool things in Yum is that it can not only install software for you from online repositories but it can also take care of all of the inter-file dependency hell associated with installing a 3rd party RPM file. To do this simply run the command

yum install yourarchive.rpm

and it will check all of the dependencies for you and automatically queue up the files it needs to install, just like it was getting the file from a repository in the first place. Very handy when you're beta testing software.

Another tip is related to this. When I did the above it queued up all of the extra files I needed, then complained that it couldn't recognize the electronic signature attached to the new program I was installing, specifically it said:

Public key for <filename> is not installed

A quick google later and I discovered there's a little trick you can do but are generally advised not to. You see when you're updating software using Yum it verifies that all of the software is coming from somewhere reputable, so it keeps track of the signatures for each repository it knows about. The obvious problem then is that if you're installing a once-off file there's no server to have a signature from, so it shrugs its shoulders and gives up. The temporary fix for this is to change a line in the file /etc/yum.conf that says

gpgcheck=1

Simply change that to =0 and you're away with it! Do make sure to change it back afterwards, though, you want to keep this security precaution in place for normal use.

I hope these can help others who get stuck.

How to reply

Care to add your own 2 cents? Let me know via Twitter or my contact page.