Timothy Murphy wrote:
Steve Searle wrote:
Why does "yum remove foo" try to remove every package
using anything required by foo?
Surely the rational strategy would be to leave anything
required by another package?
No. You asked it to remove foo. It is rational that it does as you
requested. It would be irrational to:
- not do as you asked, or
- leave behind broken packages because it removed foo
You misunderstood me (I think)
As far as I can see, "yum remove foo" removes foo,
and also everything that foo depends on.
Then it removes everything that depends on the things already removed.
And so ad infinitum.
I would have thought it would be more logical
to leave anything required by another package.
Of course anything that requires foo should be removed.
But that is a different matter.
Are you willing to say which package in particular ?
If not, running:
rpm -q --requires package-yum-wanted-to-remove
will tell you whether yum is doing the right thing according to how the
application/library has been packaged.
If it is in fact doing the wrong thing, either yourself or someone else
will need a repeatable example to make a bug report at
bugzilla.redhat.com.
Sometimes a package is a meta-package whose job it is to install a heap
of sub packages.
eg: xorg-x11-drivers installs xorg-x11-drv-* so that all drivers will be
available should the hardware get changed. This means if you want yum to
uninstall one of the -drv-* packages, since it is required by -drivers,
yum then adds -drivers to the remove list which then requires the
removal of the rest of the -drv-* subpackages, and so on.
The above example can be worked around {although the Fedora developers
recommend all -drv-* stay installed}, by removing the meta-package first
{xorg-x11-drivers}, then any individual -drv-* that you are sure you
wont need.
DaveT.