Printable Version of Topic

Click here to view this topic in its original format

Linuxhelp _ Tips and Tricks _ How To Use Apt On Redhat / Fedora Core

Posted by: hughesjr Oct 23 2004, 06:15 AM

I have long used the Dag / NewRPMs / ATrpms / FreshRPMS apt repositories to keep my RedHat and FedoraCore installs updated and to install (and maintain) packages that are not included in the original Distros.

There are 4 sites that work together to maintain a of packages not included with the original installs.

Here are the 4 individual sites:

How to use APT for RedHat / Fedora

1. Go to the FreshRPMS and download the apt RPM for you version of RedHat / Fedora. Select your version and download the top file (usually named (the version is different for each version of RedHat / Fedora linux).

2. Open a terminal window (as the root user) and install the package via the command:

rpm -Uvh

3. Edit the file /etc/apt/sources.list and replace the contents with the following (I'll cover RH9, FC1 and FC2)

RedHat 9

# FreshRPMS
rpm redhat/9/i386 core updates freshrpms

# Dag Apt Repository
rpm redhat/9/en/i386 dag
rpm redhat/en/i386/9.0 newrpms

rpm redhat/9/en/i386 at-stable

Fedora Core 1
# FreshRPMS
rpm fedora/linux/1/i386 core updates freshrpms

# Dag Apt Repository
rpm redhat/fc1/en/i386 dag
rpm redhat/en/i386/fc1 newrpms

rpm fedora/1/en/i386 at-stable

Fedora Core 2
# FreshRPMS
rpm fedora/linux/2/i386 core updates freshrpms

# Dag Apt Repository
rpm redhat/fc2/en/i386 dag
rpm redhat/en/i386/fc2 newrpms

rpm fedora/2/en/i386 at-stable

4. After saving the proper sources.list, update the package lists of the software to the latest levels with this command:

apt-get update

5. Next upgrade your installed packages to the latest versions:

apt-get dist-upgrade

6. You can also use apt to search for packages ... like this:

apt-cache search search term

7. You can install packages with the command:

apt-get install package name

8. Prior to using console apt commands, update your reference lists with a apt-get update.

9. There is a GUI for package install and research as well, to get it use the command:

apt-get install synaptic

to run synaptic ... use the command (at the terminal as root) synaptic

10. Whenever you want to update your system, do (I do mine at least once a week):

apt-get update
apt-get dist-upgrade

this will install all updates to all the RPM packages installed by the original system and installed via the 4 site merged repositories.

11. Kernels (and kernel-source {rh9/fc1} ... kernel-sourcecode{fc2}) are different ... they are not updated via the normal apt-get process. You can see which kernel you have installed and what is available with the comamnd:

apt-get install kernel

You will get a list like this:

Reading Package Lists... Done
Building Dependency Tree... Done
Package kernel is a virtual package provided by:
 kernel-smp#2.4.22-1.2199.nptl 2.4.22-1.2199.nptl
 kernel-smp#2.4.22-1.2197.nptl 2.4.22-1.2197.nptl
 kernel-smp#2.4.22-1.2194.nptl 2.4.22-1.2194.nptl
 kernel-smp#2.4.22-1.2188.nptl 2.4.22-1.2188.nptl
 kernel-smp#2.4.22-1.2179.nptl 2.4.22-1.2179.nptl
 kernel-smp#2.4.22-1.2174.nptl 2.4.22-1.2174.nptl
 kernel-smp#2.4.22-1.2140.nptl 2.4.22-1.2140.nptl
 kernel#2.4.22-1.2199.nptl 2.4.22-1.2199.nptl
 kernel#2.4.22-1.2197.nptl 2.4.22-1.2197.nptl [Installed]
 kernel#2.4.22-1.2194.nptl 2.4.22-1.2194.nptl
 kernel#2.4.22-1.2188.nptl 2.4.22-1.2188.nptl
 kernel#2.4.22-1.2179.nptl 2.4.22-1.2179.nptl
 kernel#2.4.22-1.2174.nptl 2.4.22-1.2174.nptl
 kernel#2.4.22-1.2140.nptl 2.4.22-1.2140.nptl
 kernel-smp#2.4.22-1.2115.nptl 2.4.22-1.2115.nptl
 kernel#2.4.22-1.2115.nptl 2.4.22-1.2115.nptl
You should explicitly select one to install.
E: Package kernel is a virtual package with multiple good providers.

(this is from my current FC1 install)
I don't have the latest kernel installed ... so I can install it with the command:

apt-get install kernel#2.4.22-1.2199.nptl

Same for kernel-source and kernel-sourcecode ....

You can also use synaptic to install kernel, kernel-source, and kernel-sourcecode.

Another note about kernels ... ATrpms makes custom kernels. You will know them by .at at the end of the name. (in the above example, Those kernels are specially made, and are not as easy to maintain as the default kernels ... I don't recommend you install the AT kernels unless you are doing so per the instructions on his site, and for a specific reason.

Posted by: Corey Nov 22 2004, 09:18 AM

A few notes to add to this guide:

It is suggested, for stability-sake, that you should setup apt with a freshly installed system, or a system who's RPM database isn't a mess due to previous forces of rpm installs.

Also, this tools is available for SUSE (for which i use), the information can be on how to set this up for different versions of SUSE.

Powered by Invision Power Board (
© Invision Power Services (