[Spacewalk-list] Removing old updates from channels

Michael Mraka michael.mraka at redhat.com
Fri Sep 30 09:15:15 UTC 2011


Zakrocki, Robert wrote:
% Hello List,
% 
% Is there a way to remove old update packages from my "Updates"
% channel? When I look at the packages in my "Updates" channel I get
% number of the same packages with different version. For example:
% 
% When I look for firefox it will give me this:
% 
% firefox-5.0-2.fc15.i686 firefox-6.0-2-1.fc15.i686
% firefox-6.0-1.fc15.i686
% 
% Surely I only need the latest package in this case
% firefox-6.0-2-1.fc15.i686. This happens to a lot of packages.
% 
% This is the command I run to sync the channel
% /usr/bin/spacewalk-repo-sync --channel fedora15-updates --type yum .
% 
% It looks like the above command sync my updates channel but leaves old
% packages from the previous sync.


Spacewalk keeps old packages intentionally to be able to do rollback to
old versions.

If you really want you can remove old packages via API e.g. from a cron
scipt. I guess channel.software.listAllPackages(),
channel.software.listLatestPackages() and packages.removePackage()
should be the right puzzle pieces you need. You may use spacecmd which
is very good command-line tool to call Spacewalk API.


Regards,

--
Michael Mráka
Satellite Engineering, Red Hat




More information about the Spacewalk-list mailing list