Computer Tips - How can I find leaf and orphan packages?

Date: 2009jun10 OS: Linux Distro: RedHat/Fedora/CentOS Keywords: leafs, orphans Q. How can I find leaf and orphan packages? A. Install the yum-utils package if you don't already have it:
dnf install yum-utils
Then you can run:
package-cleanup --leaves List leaf nodes in the local RPM database. Leaf nodes are RPMs that are not relied upon by any other RPM.
package-cleanup --orphan List installed packages which are not available from currently configured repositories.
Its not automatically safe to erase the packages you find.