RPM Sync modes clarification

Problem:
I apologize in advance if this is dumb question but for me this is not clear from reading the documentation and I need to ensure sync will work as expected in prod environment.

For RPM plugin the documentation mentions the following as default SYNC mode for newly created repos unless you specify otherwise:

  • additive (the default) will retain the existing contents of the Pulp repository and add the contents of the remote repository being synced.

This statement means that if I sync a repo against the remote, new packages will be added AND also current packages that may have been updated or its version changed will also be updated locally in pulp as part of the Sync? I am confused because it seems from the text that only new contents will be added but currently present packages will not be updated/synced. I would appreciate if you can go into details with this. At this point I am not sure if I should change to mirror_content_only mode or keep additive. I am syncing RHEL/CentOS repos. Thanks a lot!!

Expected outcome:

Pulpcore version:
“core”: “3.48.0”

Pulp plugins installed and their versions:
“versions”: {
“rpm”: “3.25.1”,
“core”: “3.48.0”,
“file”: “3.48.0”,
“certguard”: “3.48.0”
},
Operating system - distribution and version:
RHEL 9

Other relevant data:

additive means:

  • You create a remote and sync it to a Pulp repo (Sync 1).
  • Some time later you sync it again to get the latest state from the remote (Sync 2).
  • If there are new packages on the remote repo, they will be added to your Pulp repo.
  • If you already have packages from Sync 1 in your Pulp repo, that have now been removed from the remote repo, those won’t be removed from your Pulp repo. Everything is purely “additive”. Each sync will add any new packages, but never remove any old packages.

By contrast “content_only” sync policy will:

  • You create a remote and sync it to a Pulp repo (Sync 1).
  • Some time later you sync it again to get the latest state from the remote (Sync 2).
  • If there are new packages on the remote repo, they will be added to your Pulp repo.
  • Any packages from Sync 1 that no longer exist on the remote repo will be removed from your Pulp repo.

=> You will have exactly those packages in your Pulp repo that were in the remote repo at the time of the last sync.

Hope that clarifies things!

3 Likes

Hi @quba42 , thanks a lot for the detailed clarification!