Red Hat Enterprise Linux 7 Server RPMs x86_64 7Server
Red Hat Enterprise Linux 7 Server - Optional RPMs x86_64 7Server
are failing with following error:
Parsing interrupted: The repository metadata being synced into Pulp is erroneous in a way that makes it ambiguous (duplicate PKGIDs), and therefore we do not allow it to be synced in ‘mirror_complete’ mode. Please choose a sync policy which does not mirror repository metadata.
Please read Error message (or warning) about ambiguous metadata during sync · Issue #2402 · pulp/pulp_rpm · GitHub for more details.
Foreman and Proxy versions:
Foreman and Proxy plugin versions:
Distribution and version:
CentOS Linux release 7.9.2009 (Core)
Other relevant data:
The suggested solution is not valid
change the repository Mirroring Policy From Complete Mirroring to Additive as this option is not available.
Is there another way to fix the duplicate PKGIDs?
On the repository page for any RPM based (yum type) repo, at the bottom of the “Sync Settings” section, there is “Mirroring Policy”. “Mirroring Policy” has a drop down menu to set it’s value, that offers the three values “Additive”, “Content Only”, “Complete Mirroring”. I believe the error message is asking you to choose anything other than “Complete Mirroring”, though I am not entirely sure if “Content Only” is also Ok, or if it has to be “Additive”.
Changing the “Mirroring Policy” is the only way to sync an affected repo. (Unless you can get the person hosting that repository to fix the repo itself).
Hi @quba42 ,
I don’t have that option:
On the CLI this option is also not available:
Then that must be because I am on a newer Foreman/Katello version than you are. I thought this option had always been there, and I am not sure what version added it, but I have it on Foreman 3.3.1, Katello 4.5.1.
The latest version is Foreman 3.7 and Katello 4.9. I think only the latest two or three Y releases are officially supported, so Foreman 3.0 and Katello 4.2 are definitely unsupported. I am afraid you are not likely to get any solutions that do not involve “you have to upgrade to a newer version” for this particular problem.
Iirc, the “Mirroring Policy” setting was introduced in Foreman 4.3 or 4.4 to better reflect what Pulp does in the backend.
In earlier versions, the “Mirror on Sync” option should be what you are looking for. You can try changing that to no, which should be the equivalent of “Additive” policy (Adding new packages, not deleting old ones, and not syncing the metadata but instead generating metadata locally).
Nevertheless, like quba42 already mentioned, your Foreman version is way outdated and out of support for ~1.5 years, so updating to a recent version would definitely be a good thing to do.
For now, the Mirror on Sync option will do.
I am migrating foreman to AlmaLinux 8 so I can install the latest version of Foreman