Open marmau06 opened 2 months ago
@meaksh FYI
I think there is a little misunderstanding what --latest
means. This options filters the list of packages to sync so that only the latest version of each package is synced. It's expected that there is only one package version for "kernel-4.18.0" when --latest
is used.
Looking at the determination of "latest package version" here, I agree that this is a bug. We use Salt's LooseVersion()
in our yum_src reposync plugin, but that gives us the wrong result in this case.
>>> a = "kernel-4.18.0-553.el8_10"
>>> b = "4.18.0-553.16.1.el8_10"
>>> LooseVersion(a) > LooseVersion(b)
True
vs
% rpmdev-vercmp kernel-4.18.0-553.el8_10 4.18.0-553.16.1.el8_10
rpmdev-vercmp kernel-4.18.0-553.el8_10 4.18.0-553.16.1.el8_10
WARNING: hyphen in release1: 4.18.0-553.el8_10
rpmdev-vercmp <epoch1> <ver1> <release1> <epoch2> <ver2> <release2>
rpmdev-vercmp <EVR1> <EVR2>
rpmdev-vercmp # with no arguments, prompt
Exit status is 0 if the EVR's are equal, 11 if EVR1 is newer, and 12 if EVR2
is newer. Other exit statuses indicate problems.
kernel-4.18.0-553.el8_10 < 4.18.0-553.16.1.el8_10
Problem description
spacewalk-repo-sync and "--latest" do not show latest packages.... and seems to only show one version for each package..
Steps to reproduce
1.For example, for RHEL8 repository, use "spacewalk-repo-sync and "--latest" Here we can see only kernel-4.18.0-553.el8_10.x86_64.
3.Once spacewalk-repo-sync has been used without "--latest", Uyuni proposal is bigger (209 kernel packages instead of three), and include the latest version of kernel:
...
Uyuni version
Uyuni proxy version (if used)
Useful logs
Additional information
We tried to upgrade Uyuni to the latest version (2024-07) just to see if this behavior is still present... We got other big issues with spacewalk-repo-sync command, which do not work anyumore for other reason... So we have the workaround to remove the "--latest" switch to the command used, but it seems that "latest" package is not well managed by Uyuni.