Often installing a package would pull a bunch of other dependencies into the system.
But they won’t get removed by default when you remove the original package you installed.
In Debian world there is “apt-get autoremove”
Actually Yum has a config option to turn on auto removal!
Just add this line to your /etc/yum.conf
# Auto remove dependencies on package removal clean_requirements_on_remove = True
Then yum will to remove unnecessary dependency automatically from now on.
For existing packages, it will require a bit of manual labour.
package-cleanup --quiet --leaves
Carefully examine the list and manually remove them
My /var is filling up with yum cache even after I cleaned with yum clean all, after several hours again it is filling. Can you tell me what is the actual reason for this so we can solve this permanently.