Yum Tutorial



by Tariq Khaleeq, Sanea Sheikh, Shahina Hayat

YUM stands for 'Yellowdog Updater Modified'. YellowDog Linux is a rpm based distribution of Linux created for the ppc architecture. Fedora Core took up this package manager as of Fedora Core 1.

Leaving history aside, yum is the easiest way to install, update, and remove software from your Linux systems. This quick tutorial guides you through the steps but it is not a substitute for man yum. This tutorial would give you general usage while man page give a comprehensive documentation of yum's functionality. An added benefit of yum is that it calculates a programs dependencies and then it downloads and installs them for you.

Installing Yum

Before installing yum, check to see if you already have yum installed:

$ whereis yum

If you don't have yum installed, you can download it from http://yum.baseurl.org. To install yum,

$ rpm -Uvh yum-xx.noarch.rpm

Is a software already installed on my system

$ yum list install SOFTWARE
$ yum list install firefox

replace the word software with your software.

Installing with yum

$ yum install SOFTWARE
$ yum install firefox

replace the word software with your software.
This will get all the dependencies and prompt you with a list of dependencies you need to download and install. You can accept or decline.

Search for software

$ yum search STRING
$ yum search firefox
$ yum search fire*

where string could be software's name, or a wildcard. Yum would return a list of matches.

Uninstalling software

$ yum remove PACKAGE
$ yum remove firefox

Updating software

$ yum update PACKAGE
$ yum update firefox

Error Messages

error: Cannot retrieve repository metadata (repomd.xml) for repository : fedora. Please verify its path and try again.
You would need to edit fedora.repo and fedora-updates.repo to fix this error:

$ cd /etc/yum.repos.d
$ cp fedora.repo to fedora.repo.backup

It is important to backup any configuration file before you edit it. This way, if your modifications are unsuccessful, you can easily revert back to the original.

$ vi fedora.repo 

Uncomment all baseurls and change https to http. Save changes.

$ cp fedora-updates.repo fedora-updates.repo.backup
$ vi fedora-updates.repo 

Uncomment all baseurls and change https to http. Save changes.

$ yum update 

Run update to test your new settings.