Uploaded image for project: 'Satellite'
  1. Satellite
  2. SAT-22357 Registration can't find any Capsules when their locations are not assigned to admin user
  3. SAT-22924

[QE] Registration can't find any Capsules when their locations are not assigned to admin user

XMLWordPrintable

    • Icon: Sub-task Sub-task
    • Resolution: Done
    • Icon: Undefined Undefined
    • None
    • None
    • Capsule - Content
    • Sprint 127

      +++ This bug was initially created as a clone of Bug #2254612 +++

      A commit was recently introduced to attempt to surmise when a host is being registered thru a load balancer.

      To do this, candlepin_proxies_controller needs to look through ::SmartProxy.all to find smart proxies matching the hostname of the server receiving the registration request.

      However, if there are smart proxies assigned to locations, and those locations are not the same locations assigned to the registering user (the --username passed to subscription-manager), Rails will act as if those smart proxies don't exist.

      The effect is that Katello doesn't have access to its own list of smart proxies, and so doesn't know how to correctly assign a content source.

      So the host will get registered, and its "registered_through" smart proxies for REX will be correct, but content source will be incorrectly nil.

      — Additional comment from on 2023-12-14T20:50:08Z

      Created from redmine issue https://projects.theforeman.org/issues/36989

      — Additional comment from on 2023-12-14T20:50:10Z

      Upstream bug assigned to None

      — Additional comment from on 2023-12-14T20:53:50Z

      Proposing for 6.14.z and 6.15.0 since this is following up https://bugzilla.redhat.com/show_bug.cgi?id=2240956

      — Additional comment from on 2023-12-14T21:05:13Z

      I think this bug would affect all registrations, not just those thru a load balancer

      — Additional comment from on 2023-12-14T21:07:54Z

      All registrations to capsules not assigned the same location as the registering user, that is

      — Additional comment from on 2023-12-15T00:02:48Z

      Upstream bug assigned to jlenz@redhat.com

      — Additional comment from on 2023-12-15T00:02:51Z

      Upstream bug assigned to jlenz@redhat.com

      — Additional comment from on 2023-12-15T21:41:07Z

      In my testing the only hosts that get ' Content Source' populated are the ones behind a LB capsule:

      ```

      1. for CONTENT_HOST in containerhost-hq-1-container10.blue.ddns.perf.redhat.com containerhost-a-1-container10.blue.ddns.perf.redhat.com containerhost-b-1-container10.blue.ddns.perf.redhat.com containerhost-b-2-container10.blue.ddns.perf.redhat.com; do echo; echo $CONTENT_HOST; hammer host info --name $CONTENT_HOST | grep -A2 'Content Source'; done

      containerhost-hq-1-container10.blue.ddns.perf.redhat.com <- Registered against the Sat server
      Content Source:
      Id:
      Name:

      containerhost-a-1-container10.blue.ddns.perf.redhat.com <- Registered against a standalone capsule
      Content Source:
      Id:
      Name:

      containerhost-b-1-container10.blue.ddns.perf.redhat.com <- Registered against a LB capsule
      Content Source:
      Id: 3
      Name: capsule-b-1.blue.ddns.perf.redhat.com

      containerhost-b-2-container10.blue.ddns.perf.redhat.com <- Registered against a LB capsule
      Content Source:
      Id: 3
      Name: capsule-b-1.blue.ddns.perf.redhat.com
      ```

      — Additional comment from on 2023-12-19T20:02:55Z

      Moving this bug to POST for triage into Satellite since the upstream issue https://projects.theforeman.org/issues/36989 has been resolved.

      QE Tracker for https://issues.redhat.com/browse/SAT-22357
      Bugzilla: https://bugzilla.redhat.com/show_bug.cgi?id=2257332
      Bugzilla: https://bugzilla.redhat.com/show_bug.cgi?id=2254612

              vsedmik@redhat.com Vladimír Sedmík
              satellite-focaccia-bot Focaccia Bot
              Vladimír Sedmík Vladimír Sedmík
              Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

                Created:
                Updated:
                Resolved: