Successfully able to register host to subscription manager, but yum update fails :(

Problem: When doing a yum update now that my host is registered to my Katello server: [Errno 14] HTTPS Error 404 - Not Found

Expected outcome:
For yum update to properly pull

Foreman and Proxy versions:

Any ideas why this could be happening?

What’s interesting is that in the product view it says this:
Publish via HTTPS


Publish via HTTP


Published At

But my yum update tries to pull the same url but https?

Hey @ado120,

When you set the publish via HTTP, the repo is still published over HTTPS as well. The HTTP location is available to browse but hosts will use HTTPS.

For the 404 though, would you be able to verify that the content view has the repository added and a new version was published with the repo?

Thank you for the prompt response. I’ve checked the content view and see that the latest version is posted and LifeCycle environment is “Library” which the activation key is set to… any other ideas? Maybe I need to curl the .rpm file from http and not https?

It looks like doing the initial curl command with http didn’t solve the issue either :frowning:

Are you able to browse the repo by going in the directory on you foreman server (should be something like this) :
var/lib/pulp/published/yum/http/repos/Default_Organization/Library/custom/example_foreman/foreman_1_21_el7/ and find the repomd?

Another thing you could do is to try and move your system to the default organization cv and check if you still get the 404. Also, could you get the apache logs for when you do hit the 404.

the repomd file is there and looks to be valid… However here is the last few lines of the foreman-ssl_access.log

Blockquote - - [24/Jan/2019:14:40:51 -0800] “GET /rhsm/consumers/94a7d190-4e7a-4f86-9b8f-64c135b2fda2/certificates?serials=7939229270215010828 HTTP/1.1” 200 4657 “-” “RHSM/1.0 (cmd=subscription-manager)” - - [24/Jan/2019:14:40:52 -0800] “GET /rhsm/status HTTP/1.1” 200 373 “-” “RHSM/1.0 (cmd=subscription-manager)” - - [24/Jan/2019:14:40:52 -0800] “GET /rhsm/consumers/94a7d190-4e7a-4f86-9b8f-64c135b2fda2/content_overrides HTTP/1.1” 200 2 “-” “RHSM/1.0 (cmd=subscription-manager)” - - [24/Jan/2019:14:40:52 -0800] “GET /rhsm/consumers/94a7d190-4e7a-4f86-9b8f-64c135b2fda2/compliance HTTP/1.1” 200 237 “-” “RHSM/1.0 (cmd=subscription-manager)” - - [24/Jan/2019:14:40:52 -0800] “GET /rhsm/consumers/94a7d190-4e7a-4f86-9b8f-64c135b2fda2 HTTP/1.1” 200 12394 “-” “RHSM/1.0 (cmd=subscription-manager)” - admin [24/Jan/2019:14:40:52 -0800] “GET /pulp/api/v2/tasks/fc482e09-5068-4009-ba2b-8c6ec18abf7a/ HTTP/1.1” 200 382 “-” “rest-client/2.0.1 (linux-gnu x86_64) ruby/2.5.0p0” - admin [24/Jan/2019:14:40:52 -0800] “POST /pulp/api/v2/consumers/content/applicability/ HTTP/1.1” 200 2 “-” “rest-client/2.0.1 (linux-gnu x86_64) ruby/2.5.0p0” - admin [24/Jan/2019:14:40:53 -0800] “POST /pulp/api/v2/consumers/content/applicability/ HTTP/1.1” 200 2 “-” “rest-client/2.0.1 (linux-gnu x86_64) ruby/2.5.0p0” - admin [24/Jan/2019:14:40:53 -0800] “POST /pulp/api/v2/consumers/content/applicability/ HTTP/1.1” 200 2 “-” “rest-client/2.0.1 (linux-gnu x86_64) ruby/2.5.0p0” - - [24/Jan/2019:14:40:57 -0800] “GET /rhsm/consumers/94a7d190-4e7a-4f86-9b8f-64c135b2fda2/certificates/serials HTTP/1.1” 200 32 “-” “RHSM/1.0 (cmd=yum)” - - [24/Jan/2019:14:40:57 -0800] “GET /rhsm/status HTTP/1.1” 200 373 “-” “RHSM/1.0 (cmd=yum)” - - [24/Jan/2019:14:40:57 -0800] “GET /rhsm/ HTTP/1.1” 200 1971 “-” “RHSM/1.0 (cmd=yum)” - - [24/Jan/2019:14:40:57 -0800] “GET /rhsm/consumers/94a7d190-4e7a-4f86-9b8f-64c135b2fda2/content_overrides HTTP/1.1” 200 2 “-” “RHSM/1.0 (cmd=yum)” - - [24/Jan/2019:14:40:58 -0800] “GET /pulp/repos/Default_Organization/Library/Foreman/custom/example/foreman_1_21_el7/repodata/repomd.xml HTTP/1.1” 404 338 “-” “urlgrabber/3.10 yum/3.4.3”

Is the repomd file corrupt?

Are you able to go to ( http since it would need some certs to browse the https repo on your internet browser.)
This would be your repo in the default organization view

The link your box is hitting as per the access logs, /pulp/repos/Default_Organization/Library/Foreman/custom/example/foreman_1_21_el7/
looks like in a content view Foreman which is not published with the repo? You can go to the version in the Foreman cv and browse repos inside the version to verify.

What you can do if possible is move your host to the default organization view and check if that works instead of the content view Foreman it’s currently tied to.

Thank you for all of your help on this so far.

Doing both with and without the Foreman in the URL leads me to the page in the screenshot. So both works? Are you sure this isn’t a HTTPS issue?

Actually if I go into the Packages folder through my browser, I just see a bunch of subfolders like c/ t/ etc. with nothing inside

Also, the repomd.xml isn’t found on the server… What the heck?!

This was solved here: Repomd.xml can't be found on the server?