Uploaded image for project: 'OpenShift Bugs'
  1. OpenShift Bugs
  2. OCPBUGS-43543

CatalogSource connection status not getting populated

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Unresolved
    • Icon: Normal Normal
    • None
    • 4.13.z, 4.14.z, 4.15.z, 4.17.0, 4.16.z, 4.18
    • OLM
    • None
    • Rejected
    • False
    • Hide

      None

      Show
      None

      Description of problem:

      CatalogSource was not getting its .status.connectionState not getting populated

      Version-Release number of selected component (if applicable):

      This was observed on a 4.15 ARO cluster - but its likely present on all versions

      How reproducible:

      This issue was brought to us by Andrew Block an Architect that was helping IBM Watson and Adobe. When he came to us, a CatalogSource he had created was not getting its connectionState populated even though the Pod and Service for the source were being created and were fine. The issue continued to be observed even after deleting and recreating the CatalogSource.
      
      In the end, after stepping through the code manually and cross-referencing logs, we discovered that, for some reason, the controller was blind to the source's service account, which had been created previously and not cleaned up.
      
      In the code, the issue was with [this | https://github.com/operator-framework/operator-lifecycle-manager/blob/master/pkg/controller/registry/reconciler/grpc.go#L613] if statement. It was getting triggered by `c.currentServiceAccount(source)`. Even though the service account existed, OLM was blind to it. The code is such that it does not bubble up the error, but rather tried to re-enqueue the CatSrc to get it to create the service account.Interestingly, in the same method (CheckRegistryServer) the first thing it does is check for the service account (though with the live client).
      
      The current conjecture is that the SA did not contain the cache labels introduces by SteveK's work on reducing the OLM footprint.

      Steps to Reproduce:

          1. Create a CatalogSource
          2. Copy the ServiceAccount for the source
          3. Delete the CatalogSource
          4. Edit the ServiceAccount removing all metadata (except name/namespace)
          5. Apply the modified ServiceAccount
          6. Re-create the CatalogSource

      Actual results:

          no .status.connectionState

      Expected results:

          yes .status.connectionState

      Additional info:

       

              lmohanty@redhat.com Lalatendu Mohanty
              pegoncal@redhat.com Per Goncalves da Silva
              Jian Zhang Jian Zhang
              Votes:
              0 Vote for this issue
              Watchers:
              6 Start watching this issue

                Created:
                Updated: