Hammer repository upload-content' command cannot rename a file once uploaded and upload it as a new file

Problem:
hammer repository upload-content’ command, cannot rename a file once uploaded and upload it as a new file

Expected outcome:
Expect to see the correct uploaded file(s)

Foreman and Proxy versions:
foreman-3.13.0-1.el9.noarch
foreman-proxy-3.13.0-1.el9.noarch

Foreman and Proxy plugin versions:
katello-4.15.0-1.el9.noarch

Distribution and version:
RHEL 9.5 : 5.14.0-503.34.1.el9_5.x86_64

Other relevant data:
our problem is perfectly described in this Red Hat Article from January 10 2025:

I also found some Articles in the KB, did not find however a recent solution, it looks to me as returning bug.

In our case we have had a repository w/o any upstream URL, nor sync, type = file.

Please let me know if this is patched or when is it planned to be.

Many thanks!
Jan

Hi @jr71 ,

This is an open issue in katello and Pulp, one of the backend dependencies. It is not yet triaged to an upcoming release since the fix is still being worked on. The issue stems from the old and new files having the same checksums. Because of this, the system attempts to de-duplicate content by reusing existing artifacts instead of creating new ones.

The workaround is to delete the old uploaded file, run orphan deletion and then re-upload the newer file. Please also note the setting Orphaned protection time which should be 0 if you want it cleaned up right away after removing the old file.

Thanks for the reply and “solution”.