Re: yum cleanup

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Bill Davidsen wrote, On 07/25/2009 08:32 PM:
I have been running yum with keepcache=1 to save rpms I install. Being busy I seem to have gotten several versions of some packages in /var/cache/yum. Is there a command which will delete anything listed in obsoletes without losing my copy of the most recent? I create a local archive of recent rpms to be nice to my network.

Using 'yum clean' does too much. :-(

repomanage -c -k 2 --old path/to/cacheOfRPMs/ > removethese.txt
#and then (after sanity checking removethese.txt)
for i in `cat removethese.txt`;do rm $i;done

might get you close.
Note, AFAIK the repomanage command does NOT have to be ran against a YUM repo.

Note 2, using -k 1 keeps 1 vs -k 2 keeping 2.

--
Todd Denniston
Crane Division, Naval Surface Warfare Center (NSWC Crane)
Harnessing the Power of Technology for the Warfighter

--
fedora-list mailing list
fedora-list@xxxxxxxxxx
To unsubscribe: https://www.redhat.com/mailman/listinfo/fedora-list
Guidelines: http://fedoraproject.org/wiki/Communicate/MailingListGuidelines

[Index of Archives]     [Current Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Yosemite News]     [Yosemite Photos]     [KDE Users]     [Fedora Tools]     [Fedora Docs]

  Powered by Linux