RPM1004: Error retrieving metadata: Not found

Ok. I got a work around that worked for me. Via this answer, I used the command line hammer repository synchronize --id 5 --source-url https://mirror.aarnet.edu.au/pub/epel/7/x86_64.
Initially that threw an error about preferring https instead of http, that looked like this:

Could not synchronize the repository:
Redirection of API call detected.
It seems hammer is configured to use HTTP and the server prefers HTTPS.
Update your server url configuration
you can set ‘follow_redirects’ to one of :default or :always to enable redirects following

so I then made a hand wavy guess and added https:// to the start of the :host: 'myserver' making :host: 'https://myserver' in /root/.hammer/cli.module.d/foreman.yml, then ran the hammer command successfully.

Ah, the life of a sysadmin. Stab in the dark until it works/dies. Thanks.

2 Likes