Bug 1803055

Summary: [ISV] Non operator installed for Crunchy PostgreSQL
Product: OpenShift Container Platform Reporter: Salvatore Colangelo <scolange>
Component: ISV OperatorsAssignee: Jose R. Gonzalez <jogonza>
Status: CLOSED CURRENTRELEASE QA Contact: Salvatore Colangelo <scolange>
Severity: medium Docs Contact:
Priority: unspecified    
Version: 4.4CC: aos-bugs, jiazha, mdorn, sd-ecosystem, vlaad
Target Milestone: ---   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: No Doc Update
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2022-08-25 22:10:06 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Bug Depends On:    
Bug Blocks: 1797729    

Description Salvatore Colangelo 2020-02-14 11:30:07 UTC
Description of problem:

When I try to install operator Crunchy PostgreSQL for OpenShift the installation doesn't go well

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

4.4

How reproducible:

Alway

Steps to Reproduce:
1. Install it in the Web console,  "Operators"->"OperatorHub"->"Crunchy PostgreSQL for OpenShift 

2. Verify the installation

The status remain in upgradePending on console


3. Check the status by commando line 

[scolange@scolange pkg]$ oc get sub -n default
NAME                        PACKAGE                     SOURCE                CHANNEL
crunchy-postgres-operator   crunchy-postgres-operator   certified-operators   stable

[scolange@scolange pkg]$ oc get sub -n default -o yaml
apiVersion: v1
items:
- apiVersion: operators.coreos.com/v1alpha1
  kind: Subscription
  metadata:
    creationTimestamp: "2020-02-14T11:08:21Z"
    generation: 1
    name: crunchy-postgres-operator
    namespace: default
    resourceVersion: "28569"
    selfLink: /apis/operators.coreos.com/v1alpha1/namespaces/default/subscriptions/crunchy-postgres-operator
    uid: 893c3f28-934f-42b2-9a72-f4367c78c2a3
  spec:
    channel: stable
    installPlanApproval: Automatic
    name: crunchy-postgres-operator
    source: certified-operators
    sourceNamespace: openshift-marketplace
    startingCSV: postgresoperator.v4.2.1
  status:
    catalogHealth:
    - catalogSourceRef:
        apiVersion: operators.coreos.com/v1alpha1
        kind: CatalogSource
        name: certified-operators
        namespace: openshift-marketplace
        resourceVersion: "28332"
        uid: 49048953-627a-4581-bb12-03fa578971c7
      healthy: true
      lastUpdated: "2020-02-14T11:08:21Z"
    - catalogSourceRef:
        apiVersion: operators.coreos.com/v1alpha1
        kind: CatalogSource
        name: community-operators
        namespace: openshift-marketplace
        resourceVersion: "28331"
        uid: 2b253ad8-8e82-4304-9093-c589c55c73bd
      healthy: true
      lastUpdated: "2020-02-14T11:08:21Z"
    - catalogSourceRef:
        apiVersion: operators.coreos.com/v1alpha1
        kind: CatalogSource
        name: redhat-marketplace
        namespace: openshift-marketplace
        resourceVersion: "28334"
        uid: c4438378-f824-4739-9aff-447030f325b1
      healthy: true
      lastUpdated: "2020-02-14T11:08:21Z"
    - catalogSourceRef:
        apiVersion: operators.coreos.com/v1alpha1
        kind: CatalogSource
        name: redhat-operators
        namespace: openshift-marketplace
        resourceVersion: "28342"
        uid: 8ca1056d-a97a-4d4e-a68a-2187b57f277b
      healthy: true
      lastUpdated: "2020-02-14T11:08:21Z"
    conditions:
    - lastTransitionTime: "2020-02-14T11:08:21Z"
      message: all available catalogsources are healthy
      reason: AllCatalogSourcesHealthy
      status: "False"
      type: CatalogSourcesUnhealthy
    - lastTransitionTime: "2020-02-14T11:08:23Z"
      reason: InstallComponentFailed
      status: "True"
      type: InstallPlanFailed
    currentCSV: postgresoperator.v4.2.1
    installPlanRef:
      apiVersion: operators.coreos.com/v1alpha1
      kind: InstallPlan
      name: install-hkr6n
      namespace: default
      resourceVersion: "28557"
      uid: ba0a2081-3257-4207-896d-bd033c2e179a
    installplan:
      apiVersion: operators.coreos.com/v1alpha1
      kind: InstallPlan
      name: install-hkr6n
      uuid: ba0a2081-3257-4207-896d-bd033c2e179a
    lastUpdated: "2020-02-14T11:08:23Z"
    state: UpgradePending
kind: List
metadata:
  resourceVersion: ""
  selfLink: ""


Actual results:

lastTransitionTime: "2020-02-14T11:08:21Z"
      message: all available catalogsources are healthy
      reason: AllCatalogSourcesHealthy
      status: "False"
      type: CatalogSourcesUnhealthy
    - lastTransitionTime: "2020-02-14T11:08:23Z"
      reason: InstallComponentFailed
      status: "True"
      type: InstallPlanFailed

Expected results:


Additional info:

[scolange@scolange pkg]$ oc get clusterversion
NAME      VERSION                             AVAILABLE   PROGRESSING   SINCE   STATUS
version   4.4.0-0.nightly-2020-02-13-212616   True        False

Comment 2 Melvin Hillsman 2020-02-17 20:01:40 UTC
Related to structural schema changes in 1.17 - https://kubernetes.io/docs/tasks/access-kubernetes-api/custom-resources/custom-resource-definitions/#specifying-a-structural-schema

spec:
  approval: Automatic
  approved: true
  clusterServiceVersionNames:
    - postgresoperator.v4.2.1
status:
  catalogSources:
    - certified-operators
  conditions:
    - lastTransitionTime: '2020-02-17T19:49:31Z'
      lastUpdateTime: '2020-02-17T19:49:31Z'
      message: >-
        error creating csv postgresoperator.v4.2.1:
        ClusterServiceVersion.operators.coreos.com "postgresoperator.v4.2.1" is
        invalid: [spec.customresourcedefinitions.owned.specDescriptors.value:
        Invalid value: "crunchy-postgres-ha":
        spec.customresourcedefinitions.owned.specDescriptors.value in body must
        be of type byte: "crunchy-postgres-ha",
        spec.customresourcedefinitions.owned.specDescriptors.value: Invalid
        value: "rhel7-12.1-4.2.1":
        spec.customresourcedefinitions.owned.specDescriptors.value in body must
        be of type byte: "rhel7-12.1-4.2.1",
        spec.customresourcedefinitions.owned.specDescriptors.value: Invalid
        value: "hippo":
        spec.customresourcedefinitions.owned.specDescriptors.value in body must
        be of type byte: "hippo",
        spec.customresourcedefinitions.owned.specDescriptors.value: Invalid
        value: "int64":
        spec.customresourcedefinitions.owned.specDescriptors.value in body must
        be of type byte: "int64",
        spec.customresourcedefinitions.owned.specDescriptors.value: Invalid
        value: "hippo-postgres-secret":
        spec.customresourcedefinitions.owned.specDescriptors.value in body must
        be of type byte: "hippo-postgres-secret",
        spec.customresourcedefinitions.owned.specDescriptors.value: Invalid
        value: "hippo-primaryuser-secret":
        spec.customresourcedefinitions.owned.specDescriptors.value in body must
        be of type byte: "hippo-primaryuser-secret",
        spec.customresourcedefinitions.owned.specDescriptors.value: Invalid
        value: "hippo-testuser-secret":
        spec.customresourcedefinitions.owned.specDescriptors.value in body must
        be of type byte: "hippo-testuser-secret",
        spec.customresourcedefinitions.owned.specDescriptors.value: Invalid
        value: "ReadWriteOnce":
        spec.customresourcedefinitions.owned.specDescriptors.value in body must
        be of type byte: "ReadWriteOnce",
        spec.customresourcedefinitions.owned.specDescriptors.value: Invalid
        value: "1G": spec.customresourcedefinitions.owned.specDescriptors.value
        in body must be of type byte: "1G",
        spec.customresourcedefinitions.owned.specDescriptors.value: Invalid
        value: "": spec.customresourcedefinitions.owned.specDescriptors.value in
        body must be of type byte: "",
        spec.customresourcedefinitions.owned.specDescriptors.value: Invalid
        value: "{}": spec.customresourcedefinitions.owned.specDescriptors.value
        in body must be of type byte: "{}"]
      reason: InstallComponentFailed
      status: 'False'
      type: Installed

Comment 4 Jose R. Gonzalez 2020-04-15 13:29:23 UTC
The latest version (4.2.2) of the operator has been released, published, and should now be available with fixes to resolve this. 

The upstream change, for reference, was here: https://github.com/CrunchyData/postgres-operator/pull/1388

Comment 5 Salvatore Colangelo 2020-05-05 13:17:30 UTC
Hi below the step:

1. Install it in the Web console,  "Operators"->"OperatorHub"->"Crunchy PostgreSQL for OpenShift 

2. Verify the installation


[scolange@scolange ~]$ oc get sub
NAME                        PACKAGE                     SOURCE                CHANNEL
crunchy-postgres-operator   crunchy-postgres-operator   certified-operators   stable
[scolange@scolange ~]$ oc get ip
NAME            CSV                       APPROVAL    APPROVED
install-mcxl5   postgresoperator.v4.2.2   Automatic   true
[scolange@scolange ~]$ oc get csv
NAME                      DISPLAY                            VERSION   REPLACES   PHASE
postgresoperator.v4.2.2   Crunchy PostgreSQL for OpenShift   4.2.2                Succeeded

3. Verify the status of subscription


[scolange@scolange ~]$ oc get sub -n scolange -o yaml
apiVersion: v1
items:
- apiVersion: operators.coreos.com/v1alpha1
  kind: Subscription
  metadata:
    creationTimestamp: "2020-05-05T12:49:36Z"
    generation: 1
    name: crunchy-postgres-operator
    namespace: scolange
    resourceVersion: "726009"
    selfLink: /apis/operators.coreos.com/v1alpha1/namespaces/scolange/subscriptions/crunchy-postgres-operator
    uid: 73da9741-4784-4417-9da2-9d0cadc364b2
  spec:
    channel: stable
    installPlanApproval: Automatic
    name: crunchy-postgres-operator
    source: certified-operators
    sourceNamespace: openshift-marketplace
    startingCSV: postgresoperator.v4.2.2
  status:
    catalogHealth:
    - catalogSourceRef:
        apiVersion: operators.coreos.com/v1alpha1
        kind: CatalogSource
        name: certified-operators
        namespace: openshift-marketplace
        resourceVersion: "657861"
        uid: 8903cd73-d7b2-46f3-abd9-b0ee95a6feb2
      healthy: true
      lastUpdated: "2020-05-05T12:49:38Z"
    - catalogSourceRef:
        apiVersion: operators.coreos.com/v1alpha1
        kind: CatalogSource
        name: community-operators
        namespace: openshift-marketplace
        resourceVersion: "657638"
        uid: 961b75e7-efd8-4c6b-9106-32ac669d9be0
      healthy: true
      lastUpdated: "2020-05-05T12:49:38Z"
    - catalogSourceRef:
        apiVersion: operators.coreos.com/v1alpha1
        kind: CatalogSource
        name: qe-app-registry
        namespace: openshift-marketplace
        resourceVersion: "657866"
        uid: cf6ea09e-9824-4b9b-9063-8b7935903dae
      healthy: true
      lastUpdated: "2020-05-05T12:49:38Z"
    - catalogSourceRef:
        apiVersion: operators.coreos.com/v1alpha1
        kind: CatalogSource
        name: redhat-marketplace
        namespace: openshift-marketplace
        resourceVersion: "657862"
        uid: d9edb038-a67e-4ab5-aa7a-66e59cd7bc34
      healthy: true
      lastUpdated: "2020-05-05T12:49:38Z"
    - catalogSourceRef:
        apiVersion: operators.coreos.com/v1alpha1
        kind: CatalogSource
        name: redhat-operators
        namespace: openshift-marketplace
        resourceVersion: "657863"
        uid: 7066b53e-8a05-44c8-a29c-770db4655da9
      healthy: true
      lastUpdated: "2020-05-05T12:49:38Z"
    conditions:
    - lastTransitionTime: "2020-05-05T12:49:38Z"
      message: all available catalogsources are healthy
      reason: AllCatalogSourcesHealthy
      status: "False"
      type: CatalogSourcesUnhealthy
    currentCSV: postgresoperator.v4.2.2
    installPlanGeneration: 1
    installPlanRef:
      apiVersion: operators.coreos.com/v1alpha1
      kind: InstallPlan
      name: install-mcxl5
      namespace: scolange
      resourceVersion: "725906"
      uid: 22d07871-706e-49bd-9234-98787209b1ad
    installedCSV: postgresoperator.v4.2.2
    installplan:
      apiVersion: operators.coreos.com/v1alpha1
      kind: InstallPlan
      name: install-mcxl5
      uuid: 22d07871-706e-49bd-9234-98787209b1ad
    lastUpdated: "2020-05-05T12:49:41Z"
    state: AtLatestKnown
kind: List
metadata:
  resourceVersion: ""
  selfLink: ""

LGMT!


[scolange@scolange ~]$ oc get clusterversion
NAME      VERSION   AVAILABLE   PROGRESSING   SINCE   STATUS
version   4.4.3     True        False         39h     Cluster version is 4.4.3

Comment 7 Red Hat Bugzilla 2023-09-15 01:29:08 UTC
The needinfo request[s] on this closed bug have been removed as they have been unresolved for 365 days