-   Red Hat (
-   -   Packages installed that weren't selected during install (

Moonman 01-04-2008 12:42 PM

Packages installed that weren't selected during install
I have setup a new Redhat EL 4 server and specifically removed certain packages from being installed, ie, sendmail, MySQL, PostgreSQL, printer functions, etc...

After the install, all of those packages listed above are showing up as installed in the packages GUI. When I attempt to remove them, I get an error about an Unlocatable package dependency.

Anyone have any idea what is causing this?

One specific example is sendmail. If I try to remove it I receive the error:

error: Failed dependencies:
/usr/bin/sendmail is needed by (installed) redhat-lsb-3.0-8.EL.i386
smtpdaemon is needed by (installed) mdadm-1.12.0-2.i386

The goal is to get a minimal system setup to run oracle and one other specific software program.



kilgoretrout 01-04-2008 02:31 PM

Your rpm database may be corrupted. The first thing I would try is rebuilding the rpm database with:

# rpm --rebuilddb

Then try using the gui tools to get rid of the packages you don't want.

jailbait 01-04-2008 02:33 PM

When package A is a dependency of package B then in order to remove A you also have to remove B.

It is possible to remove A without removing B by using the rpm command and the --nodeps option. For example:

rpm --nodeps -e A


man rpm

If you do this then B may fail to run because A is missing. When you start installing and uninstalling using --nodeps then you have to handle dependency issues manually instead of letting Red Hat take care of it.

Steve Stites

Moonman 01-04-2008 02:49 PM

kilgoretrout, it is not the rpm database. System is built from kickstart file. Same situation exists if I re-install fresh system using that kickstart file or manually using same package selections.

jailbait, thanks for the tutorial, I get that, but I want solve the root cause of the problem. How are packages I didn't select getting installed. I was able to remove sendmail and mysql but had to remove 7 or 8 other packages first. I am looking to automate RHEL install and having to manually remove 8 packages doesn't really fit into a nice clean install.


jailbait 01-04-2008 03:19 PM


Originally Posted by Moonman (Post 3011495)

jailbait, thanks for the tutorial, I get that, but I want solve the root cause of the problem. How are packages I didn't select getting installed.


I haven't done a Red Hat install in a while but based on what I remember there are two possibilities for the extra packages. The first is dependencies. When you select a package the installer will automatically select all of its dependencies also. And it will select dependencies of dependencies et cetera. Some installers notify you of the automatic additions and some don't. As I remember Red Hat it did not tell you about added dependencies at install time.

The other possibility is package groups. You might select something like "email client" and Red Hat installs several email clients letting you try out and choose which one you prefer. I know that Fedora installs by package groups and possibly Red Hat does too. You could check the installer to see if it has an "All" option where it lists every package available and lets you select or omit individual packages.

Steve Stites

Moonman 01-04-2008 03:28 PM

Bingo. I think you are right on the dependencies getting picked up automatically.

Anyone know of a tool (or rpm switch) that will display the packages on a RedHat machine grouped or sorted by dependencies? I've selected about 40-50 packages for this install, but after installed the machine has over 650 packages installed (rpm -qa output is 657 lines in length)

twk 01-10-2008 04:08 PM

I found it's helpful to not include any group in kickstart to trim down installation size. Rather it's better list the software/package you want manually.
%packages --resolvedeps

All times are GMT -5. The time now is 01:26 PM.