I just switched from Ubuntu to Fedora14. In Ubuntu we had the
apt-get autoremove thing to remove orphan/unused packages. What is the counterpart in Fedora?
migrated from stackoverflow.com Oct 26 '11 at 14:31
This question came from our site for professional and enthusiast programmers.
you need to install the yum plugin "remove-with-leaves":
Recent versions of yum (e.g. as available on Fedora 20/RHEL 7) provide a
which tries to remove all automatically installed and otherwise unused dependency packages - should be pretty much equivalent to
which removes examplepackage and all its automatically installed (and otherwise unused) dependencies.
Change the behavior of yum removes
Yum supports a config option to change the default behavior of the
When this is set, the next
You can also temporarily test this option via something like:
Workaround for old Fedora version
(For Fedora versions where the yum autoremove subcommand is not available and/or
Although during installation of packages installed dependencies are marked as such (seems to be relatively new feature of rpm/yum).
You can find unneeded dependencies via:
This command line is inspired by fenris02's script.
After inspection of
DNF, the successor of yum also provides a
Building upon Larry Mohr's answer:
(Includes skipping for fastest mirror, if you wonder.)