CSUF LogoCSUF Site Navigation
optics.csufresno.edu

FC6 Setup for Installing Applications Repositories & Updates

Department of Electrical and Computer Engineering
Assistant Professor Gregory R. Kriehn
Forums
Wiki
FC6 Repositories & Updates
As mentioned in the web page discussing yum, updates can be readily performed with the following command:
~> sudo yum update
But what happens when a particular package or dependency cannot be found? Enter the Repository.

Additional repositories besides the default fedora-updates.repo and the fedora-extras.repo repositories can easily be setup. However, before proceeding any further, it is important to note that life is not all peachy keen in Repositoryland. Stanton Finley does a wonderful job in providing a special warning about the mixing of incompatible repositories — so much so, that I am going to quote him here:

We will be using the program applications Yum and Yumex described below as methods to obtain software and to update your Fedora Core installation. You will be configuring these programs by adding repositories which are groups of software created by third party packagers that we use in addition to original Fedora Core and Fedora Extras repositories that come standard with your new installation.

As you continue please keep the following in mind: You should not use the livna.org repository in conjunction with the dag/freshrpms/dries/newrpms (RPMforge) collection of rpms in your configuration files for automatic updates. Use one group or the other but not both. These two groups are mutually incompatible and can cause errors in your installation if used together for automatic updates. Regardless of which group you choose you should also avoid using the ATrpms repository in your yum or apt configuration files for these reasons. Some additional information can be found here.

With this being said please note that it is nonetheless possible to obtain single RPM packaged applications from incompatible third party repositories in cases where such packages do not create errors when installed with yum. More specifically it is possible to configure other repositories with their enable flags set to "0" (off) so that the yum "--enablerepo" command must be used when one of those packages is desired.

I myself subscribe to the RPMforge collection as you can see in my repository selection instructions below. The dag/freshrpms/dries/newrpms/PlanetCCRMA (RPMforge) repositories have provided me with all of the programs I have needed as additions to the Fedora base.

There are five repositories that will be setup (although, only 4 will be enabled by default due to the warning about livna.org):  freshrpms, dries, macromedia, didier, and livnafreshrpms, dries, and macromedia basically provide packages relating to multimedia software, didier provides Fedora Core packages for the Enlightenment Windows Manager DR17 (also known as E17), and livna will be disabled by default (but can be used under special circumstances to install or upgrade specific packages such as the NVidia video driver and pine).
It is important to set up all of the repositories now, since some of the repositories depend upon other ones (such as didier with freshrpms). Furthermore, the rest of the HOWTO pages are almost entirely dependent having the repositories already setup.

freshrpms
The freshrpms homepage is found at:

http://freshrpms.net/

Installation of the repository file freshrpms.repo to /etc/yum.repos.d/ can be performed by installing the appropriate .rpm file. Simply click on the "click here" link from the website to download the .rpm file. Once finished, type:
~> sudo rpm -vhi freshrpms-release-1.1-1.fc.noarch.rpm
In this case, the .rpm file also copies the freshrpms General Public Key (GPG key) to /etc/pki/rpm-gpg/RPM-GPG-KEY-freshrpms and automatically imports the key. The system is now ready fetch rpm packages from freshrpms using yum. To verify this, take a look at the /etc/yum.repos.d/freshrpms.repo file that was just created. You should see something similar to the following:
[freshrpms]
name=Fedora Core $releasever - $basearch - Freshrpms
#baseurl=http://ayo.freshrpms.net/fedora/linux/$releasever/$basearch/freshrpms/
mirrorlist=http://ayo.freshrpms.net/fedora/linux/$releasever/mirrors-freshrpms
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-freshrpms
gpgcheck=1
enabled=1
Notice that the file contains a mirrorlist, the location of the General Public Key, whether or not rpm should check downloaded packages from freshrpms against the key, and whether or not the repository should be enabled.

dries
The dries homepage is found at:

http://dries.ulyssis.org/rpm/

To setup the repository, the GPG key must first be imported. 
Download the file, which is located at http://dries.ulyssis.org/rpm/RPM-GPG-KEY.dries.txt. Then move it to /etc/pki/rpm-gpg, and change the ownership of the file to root:
~> sudo mv ~/Desktop/RPM-GPG-KEY.dries.txt /etc/pki/rpm-gpg/RPM-GPG-KEY-dries
~> sudo chown root.root /etc/pki/rpm-gpg/RPM-GPG-KEY-dries
Notice that I have changed the name of the file slightly. Next, import the key:
~> sudo rpm --import /etc/pki/rpm-gpg/RPM-GPG-KEY-dries
Then setup the repository file by creating a /etc/yum.repos.d/dries.repo file with the following information:
[dries]
name=Extra Fedora rpms dries - $releasever - $basearch
baseurl=http://ftp.belnet.be/packages/dries.ulyssis.org/fedora/linux/$releasever/$basearch/dries/RPMS/
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-dries
gpgcheck=1
enabled=1
Once finished, save and exit. dries is now ready for use.

macromedia
The macromedia homepage is found at:

http://macromedia.mplug.org/

To setup the repository, the GPG key must first be imported. 
Download the file, which is located at http://macromedia.mplug.org/FEDORA-GPG-KEY. Then move it to /etc/pki/rpm-gpg, and change the ownership of the file to root:
~> sudo mv ~/Desktop/FEDORA-GPG-KEY /etc/pki/rpm-gpg/RPM-GPG-KEY-macromedia
~> sudo chown root.root /etc/pki/rpm-gpg/RPM-GPG-KEY-macromedia
Notice that I have changed the name of the file slightly. Next, import the key:
~> sudo rpm --import /etc/pki/rpm-gpg/RPM-GPG-KEY-macromedia
Then setup the repository file by creating a /etc/yum.repos.d/macromedia.repo file with the following information:
[macromedia]
name=Macromedia for i386 Linux
baseurl=http://macromedia.rediris.es/rpm/
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-macromedia
gpgcheck=1
enabled=1
Once finished, save and exit. macromedia is now ready for use.

didier
The didier homepage is found at:

http://sps.nus.edu.sg/~didierbe/index.html

Installation of the repository file didier.repo to /etc/yum.repos.d/ can be performed by installing the appropriate .rpm file. Simply click on the "dc-fc6-yum-repo-1.0-1.fc6.noarch.rpm" link from the website to download it, and once finished, type:
~> sudo rpm -vhi ~/Desktop/dc-fc6-yum-repo-1.0-1.fc6.noarch.rpm
In this case, the .rpm file also copies the didier General Public Key (GPG key) to /etc/pki/rpm-gpg/RPM-GPG-KEY.didier.txt but does not import it. Let's change the name of the key and import it:
~> sudo mv /etc/pki/rpm-gpg/RPM-GPG-KEY.didier.txt /etc/pki/rpm-gpg/RPM-GPG-KEY-didier
~> sudo rpm --import 
/etc/pki/rpm-gpg/RPM-GPG-KEY-didier
Unfortunately, I've found that didier still does not have his base repository setup, except for the mirror based in the United Kingdom. Regardless, we still have to edit /etc/yum.repos.d/didier.repo file and change the name of the gpgkey.
[Didier]
name=Didier's FC6 yum repository for e17 apps/lib
baseurl=http://www.atsweb.neu.edu/bcasse/fedora/6/en/i386
   http://dr17.saaf.co.uk/fedora/6/en/i386
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-didier
gpgcheck=1
enabled=1
Save and exit. didier is now ready for use.

livna
The livna homepage is found at:

http://rpm.livna.org/

Since we have to be careful with
livna, we are going to set it up by hand. First, the GPG key must be imported. Download the file, which is located at http://rpm.livna.org/RPM-LIVNA-GPG-KEY. Then move it to /etc/pki/rpm-gpg, and change the ownership of the file to root:
~> sudo mv ~/Desktop/RPM-LIVNA-GPG-KEY /etc/pki/rpm-gpg/RPM-GPG-KEY-livna
~> sudo chown root.root /etc/pki/rpm-gpg/RPM-GPG-KEY-livna
Next, import the key:
~> sudo rpm --import /etc/pki/rpm-gpg/RPM-GPG-KEY-livna
Then setup the repository file by creating a /etc/yum.repos.d/livna.repo file with the following information:
[livna]
name=Livna for Fedora Core $releasever - $basearch - Base
baseurl=http://rpm.livna.org/fedora/$releasever/$basearch/
http://livna.cat.pdx.edu/fedora/$releasever/$basearch/
http://wftp.tu-chemnitz.de/pub/linux/livna/fedora/$releasever/$basearch/
http://ftp-stud.fht-esslingen.de/pub/Mirrors/rpm.livna.org/fedora/$releasever/$basearch/
failovermethod=priority
#mirrorlist=http://rpm.livna.org/mirrorlist-6
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-livna
gpgcheck=1
enabled=0
Once finished, save and exit. Notice that with livna, the repository is disabled by default to prevent contamination with fedora-extras. However, the repository can be used to install/upgrade very specific packages by using the command:
~> sudo yum --enablerepo livna install [package name]
We will use this when installing the Nvidia driver and pine in the appropriate HOWTOs.

A Final Note about using Repositories

In closing, I would like to quote
Stanton Finley once again (having cleaned up his grammar), since he provides some useful information if you are having trouble with a particular repository. I also mentioned something similar at the bottom of the yum page.

You can temporarily disable a troublesome repository with a command such as "yum -y update --disablerepo macromedia" [using sudo]. This is especially useful if you get the message "No more mirrors to try..." which occurs occasionally when the mirrors are very busy or down. To clean your repository data and get a fresh list of updates, do a "yum clean all", followed by a "yum -y update" [using sudo]. Please see the official Fedora Core Yum guide at http://fedora.redhat.com/docs/yum/ for more details about yum and its configuration.

Tip:  Some users have reported better success with yum updates if they edit the repository files in the /etc/yum.repos.d directory and remove the comment mark ("#") from the beginning of the "baseurl=" lines, especially if they are getting "Error: Cannot find a valid baseurl for repo:" errors.
 
Aside from that, installing most applications will now be a snap, especially with all of the repositories setup in advance.