Ask Your Question

Clean up yum cache after switching to dnf

asked 2016-07-14 05:21:50 -0600

techtonik gravatar image

updated 2016-09-19 02:13:13 -0600

I've got about 2Gb of space wasted by yum cache, and I can't find how to properly clean it with either yum or dnf.

disk usage

dnf clean all doesn't help, and yum clean all is redirected to it.

$ sudo yum clean all
Yum command has been deprecated, redirecting to '/usr/bin/dnf clean all'
edit retag flag offensive close merge delete

2 Answers

Sort by ยป oldest newest most voted

answered 2016-07-14 09:19:06 -0600

florian gravatar image

updated 2016-07-14 09:22:42 -0600

You can manually remove the old cache:

1.) su - (will ask for root password)

2.) rm -rf /var/cache/yum/x86_64/*

3.) exit

(Or you combine step 1, 2, and 3: sudo rm -rf /var/cache/yum/x86_64/*)

edit flag offensive delete link more


This looks like a hack or a workaround. Why standard methods don't do the job?

techtonik gravatar imagetechtonik ( 2016-07-27 05:12:11 -0600 )edit

I guess it doesn't worth to wait for the answer anymore, so I just removed everything manually.

techtonik gravatar imagetechtonik ( 2016-09-19 03:51:38 -0600 )edit

answered 2016-09-19 02:25:30 -0600

sideburns gravatar image

If you want to use yum to clear the cache and not just delete it, try this:

sudo yum-depricated clean all

because the yum executable has been renamed to yum-depricated.

edit flag offensive delete link more



florian gravatar imageflorian ( 2016-09-19 11:42:13 -0600 )edit

Thank you; I sit corrected.

sideburns gravatar imagesideburns ( 2016-09-19 13:09:20 -0600 )edit

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools

1 follower


Asked: 2016-07-14 05:21:50 -0600

Seen: 1,701 times

Last updated: Sep 19 '16