My first contribution to the site will cover some basics about yum (so Debian users can skip this, sorry for that). Yum is the standard package manager of CentOS and Fedora Core. It is used for maintenance of your software on your system. Most common tasks are installing and removing software on your system. In the background yum can update all software and â€“ very important â€“ can solve software dependencies automatically (a thing, the simple RPM command canâ€™t do). Solving software dependencies means: yum knows when program A needs program B to work and will also install program B if you choose to install program A.
For the proper function of yum, yum needs to know what software it can install and maintain and, of course, where to find it. In package manager terms this is called a â€œrepositoryâ€. Your installation CD/DVD is a repository for example. But a lot more interesting are repositories on the internet. These can provide (security) updates to existing software on your system and extra software which is not available on your installation CDs/DVD. And, of course, you can use different repositories together.
So letâ€™s add a new repository to yum. On CentOS 4, each repository has an extra file in the directory â€œ/etc/yum.repos.dâ€. On other systems, you may have to add the repositories directly to â€œ/etc/yum.confâ€
Fill in the following lines and save it.
1 2 3 4
Here, I am using the famous repository of Dag Wieers. It contains very useful tools and addons for CentOS/Red Hat compatible systems. A good example of Dagâ€™s repository is the famous mail reader pine which is not included on the CentOS 4 installation CDs/DVD. We will install it lateron. My configuration example of Dagâ€™s repository should be pretty self-explaining. Normally, every yum repository on the internet has a website that provides information with the correct configuration for their repository. At least, you will find data for the â€œbaseurlâ€ parameter.
Many repositories â€“ like Dag â€“ also digitally sign their packages to prevent modifications from hackers. To enable this check, â€œgpgcheckâ€ must be set to â€œ1â€ (like above), but you will also need to import the GPG key from the repository to make it work correctly. To import the GPG key from Dag, type:
Now, we can beginn installing software. Letâ€™s take pine for example.
Easy as that. And to remove it (yes, you guessed right):
To search for software across all repositories:
So, thatâ€™s all for today. In the future, I am planning another article about yum, covering some more advanced functions and bringing some more useful repositories to you to satisfy all your software needs :–)