Fedora Linux Support Community & Resources Center
  #1  
Old 17th March 2011, 12:16 AM
dd_wizard Offline
Registered User
 
Join Date: Sep 2009
Posts: 2,011
linuxfirefox
What's the best way to really clean /var/cache/yum?

Is this normal after executing "sudo yum clean all?"
Code:
$ du -hs /var/cache/yum/*/*
143M	/var/cache/yum/x86_64/12
269M	/var/cache/yum/x86_64/13
379M	/var/cache/yum/x86_64/14
Most of the space seems to be taken up by a bunch of *.sqlite files, but there are seven old *.rpm files as well. Is it safe to delete the old *.rpm files? What's up with all those big *.sqlite files?

Thanks,
dd_wizard
Reply With Quote
  #2  
Old 17th March 2011, 12:20 AM
Hlingler Offline
Administrator
 
Join Date: Sep 2006
Location: Connellsville, PA, USA
Posts: 11,305
linuxopera
Re: What's the best way to really clean /var/cache/yum?

'yum clean all' does not clean up disabled repos. Enable any repo recently used but now disabled, then try 'yum clean all' again. Don't forget to disable those repo(s) again.

Newer versions of YUM retain far more data than older versions, no matter what you do.

HTH,
V
Reply With Quote
  #3  
Old 17th March 2011, 12:37 AM
kurtdriver Offline
Registered User
 
Join Date: Jul 2005
Location: Lost, I can't find my mommy!
Posts: 1,875
linuxfirefox
Re: What's the best way to really clean /var/cache/yum?

I didn't know that, thanks Hinlgler, maybe doing yum --enablerepo=* clean all would do it?
Reply With Quote
  #4  
Old 17th March 2011, 12:53 AM
Hlingler Offline
Administrator
 
Join Date: Sep 2006
Location: Connellsville, PA, USA
Posts: 11,305
linuxopera
Re: What's the best way to really clean /var/cache/yum?

Yes, but if you use '--enablerepo=*', be prepared for a possibly loooong wait, especially of any repo is down/unavailable: YUM seems to check for repo availability before it cleans it's database.

V

EDIT: In other words: YUM will first fetch metadata for any repos which it has none, then promptly clean all. Stupid YUM...
Reply With Quote
  #5  
Old 17th March 2011, 12:58 AM
dd_wizard Offline
Registered User
 
Join Date: Sep 2009
Posts: 2,011
linuxfirefox
Re: What's the best way to really clean /var/cache/yum?

Hmm, I looked around in the subdirectories, and I'll need to enable all the repos for F12 and F13 as well as those for F14. Does that work?

Thanks,
dd_wizard
Reply With Quote
  #6  
Old 17th March 2011, 12:59 AM
Hlingler Offline
Administrator
 
Join Date: Sep 2006
Location: Connellsville, PA, USA
Posts: 11,305
linuxopera
Re: What's the best way to really clean /var/cache/yum?

I would not do that. In this case, I'd manually erase them (F12/13). What use are they anyway?

V
Reply With Quote
  #7  
Old 17th March 2011, 01:19 AM
dd_wizard Offline
Registered User
 
Join Date: Sep 2009
Posts: 2,011
linuxfirefox
Re: What's the best way to really clean /var/cache/yum?

Ah, that was actually my first thought. Judicious use of rm -fr would be a lot faster, but will that confuse yum for the F14 directory?

Thanks again,
dd_wizard
Reply With Quote
  #8  
Old 17th March 2011, 01:26 AM
Hlingler Offline
Administrator
 
Join Date: Sep 2006
Location: Connellsville, PA, USA
Posts: 11,305
linuxopera
Re: What's the best way to really clean /var/cache/yum?

YUM should not be "confused" because you delete obsolete cache stuff. But in all honesty: I don't know for sure. YUM is fairly stupid.

I would not worry. Just manually purge the cruft.

V
Reply With Quote
  #9  
Old 17th March 2011, 01:29 AM
dd_wizard Offline
Registered User
 
Join Date: Sep 2009
Posts: 2,011
linuxfirefox
Re: What's the best way to really clean /var/cache/yum?

Thanks Hlingler, all gone! Hopefully I didn't break anything.

dd_wizard
Reply With Quote
  #10  
Old 17th March 2011, 02:56 PM
vallimar Offline
Registered User
 
Join Date: Jul 2008
Posts: 1,344
windows_xp_2003chrome
Re: What's the best way to really clean /var/cache/yum?

I semi-regularly just wipe out /var/cache/yum with 'rm -rf'.
It does no harm as yum will re-create and re-download metadata as needed.
Obviously though, if you have yum set to cache downloaded rpm's for whatever
reason and wish to keep them, that won't work for you.
Reply With Quote
Reply

Tags
clean, or var or cache or yum

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
abrt clean cache ?? oxala Using Fedora 1 25th September 2010 09:25 PM
clean ABRT cache, is it safe? Catastrophe Using Fedora 2 9th December 2009 06:04 PM
no cache in /var/cache/yum for fedora 5 fire-fly Installation, Upgrades and Live Media 4 26th April 2006 07:32 PM
yum CLEAN fails to clean my house blochbob Using Fedora 9 4th October 2004 02:12 PM


Current GMT-time: 08:44 (Saturday, 24-06-2017)

TopSubscribe to XML RSS for all Threads in all ForumsFedoraForumDotOrg Archive
logo

All trademarks, and forum posts in this site are property of their respective owner(s).
FedoraForum.org is privately owned and is not directly sponsored by the Fedora Project or Red Hat, Inc.

Privacy Policy | Term of Use | Posting Guidelines | Archive | Contact Us | Founding Members

Powered by vBulletin® Copyright ©2000 - 2012, vBulletin Solutions, Inc.

FedoraForum is Powered by RedHat