Bug 1921655

Summary: [OSP] Incorrect error handling during cloudinfo generation
Product: OpenShift Container Platform Reporter: Mike Fedosin <mfedosin>
Component: InstallerAssignee: Mike Fedosin <mfedosin>
Installer sub component: OpenShift on OpenStack QA Contact: weiwei jiang <wjiang>
Status: CLOSED ERRATA Docs Contact:
Severity: medium    
Priority: medium CC: igreen
Version: 4.7   
Target Milestone: ---   
Target Release: 4.7.0   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2021-02-24 15:57:05 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:

Description Mike Fedosin 2021-01-28 11:53:14 UTC
When we generate cloudinfo for future validation, sometimes we check wrong error types for 404 errors. It leads to incorrect validation results.


Testing results of different function error types:

Testing subnets.Get: It is gophercloud.ErrDefault404
Testing networkutils.IDFromName: It is gophercloud.ErrResourceNotFound
Testing flavorutils.IDFromName: It is *gophercloud.ErrResourceNotFound
Testing imageutils.IDFromName: It is gophercloud.ErrResourceNotFound

Comment 1 Pierre Prinetti 2021-01-28 16:36:40 UTC
*** Bug 1921632 has been marked as a duplicate of this bug. ***

Comment 3 weiwei jiang 2021-02-01 07:36:09 UTC
Checked with  4.7.0-0.nightly-2021-01-30-104433 and can not reproduce this issue, move to verified.

./openshift-install 4.7.0-0.nightly-2021-01-30-104433
built from commit 8e0274dbba909dfb4fce42865c213ec117138eeb
release image upshift.mirror-registry.qe.devcluster.openshift.com:5000/ocp/release@sha256:f292cc8345ca3f074464f6611f686006d2602e7fd02cabe243db664a562e07a6


$ oc get co 
NAME                                       VERSION                             AVAILABLE   PROGRESSING   DEGRADED   SINCE
authentication                             4.7.0-0.nightly-2021-01-30-104433   True        False         False      5m15s
baremetal                                  4.7.0-0.nightly-2021-01-30-104433   True        False         False      160m
cloud-credential                           4.7.0-0.nightly-2021-01-30-104433   True        False         False      167m
cluster-autoscaler                         4.7.0-0.nightly-2021-01-30-104433   True        False         False      158m
config-operator                            4.7.0-0.nightly-2021-01-30-104433   True        False         False      160m
console                                    4.7.0-0.nightly-2021-01-30-104433   True        False         False      120m
csi-snapshot-controller                    4.7.0-0.nightly-2021-01-30-104433   True        False         False      119m
dns                                        4.7.0-0.nightly-2021-01-30-104433   True        False         False      158m
etcd                                       4.7.0-0.nightly-2021-01-30-104433   True        False         False      158m
image-registry                             4.7.0-0.nightly-2021-01-30-104433   True        False         False      128m
ingress                                    4.7.0-0.nightly-2021-01-30-104433   True        False         False      147m
insights                                   4.7.0-0.nightly-2021-01-30-104433   True        False         False      154m
kube-apiserver                             4.7.0-0.nightly-2021-01-30-104433   True        False         False      156m
kube-controller-manager                    4.7.0-0.nightly-2021-01-30-104433   True        False         False      153m
kube-scheduler                             4.7.0-0.nightly-2021-01-30-104433   True        False         False      156m
kube-storage-version-migrator              4.7.0-0.nightly-2021-01-30-104433   True        False         False      123m
machine-api                                4.7.0-0.nightly-2021-01-30-104433   True        False         False      152m
machine-approver                           4.7.0-0.nightly-2021-01-30-104433   True        False         False      158m
machine-config                             4.7.0-0.nightly-2021-01-30-104433   True        False         False      158m
marketplace                                4.7.0-0.nightly-2021-01-30-104433   True        False         False      117m
monitoring                                 4.7.0-0.nightly-2021-01-30-104433   True        False         False      145m
network                                    4.7.0-0.nightly-2021-01-30-104433   True        False         False      158m
node-tuning                                4.7.0-0.nightly-2021-01-30-104433   True        False         False      158m
openshift-apiserver                        4.7.0-0.nightly-2021-01-30-104433   True        False         False      153m
openshift-controller-manager               4.7.0-0.nightly-2021-01-30-104433   True        False         False      152m
openshift-samples                          4.7.0-0.nightly-2021-01-30-104433   True        False         False      125m
operator-lifecycle-manager                 4.7.0-0.nightly-2021-01-30-104433   True        False         False      158m
operator-lifecycle-manager-catalog         4.7.0-0.nightly-2021-01-30-104433   True        False         False      158m
operator-lifecycle-manager-packageserver   4.7.0-0.nightly-2021-01-30-104433   True        False         False      119m
service-ca                                 4.7.0-0.nightly-2021-01-30-104433   True        False         False      160m
storage                                    4.7.0-0.nightly-2021-01-30-104433   True        False         False      117m

$ oc get sc
NAME                 PROVISIONER                RECLAIMPOLICY   VOLUMEBINDINGMODE      ALLOWVOLUMEEXPANSION   AGE
csi-manila-ceph      manila.csi.openstack.org   Delete          Immediate              false                  157m
standard (default)   kubernetes.io/cinder       Delete          WaitForFirstConsumer   true                   160m
standard-csi         cinder.csi.openstack.org   Delete          WaitForFirstConsumer   true                   160m


$ oc describe co storage
Name:         storage
Namespace:    
Labels:       <none>
Annotations:  include.release.openshift.io/ibm-cloud-managed: true
              include.release.openshift.io/self-managed-high-availability: true
              include.release.openshift.io/single-node-developer: true
API Version:  config.openshift.io/v1
Kind:         ClusterOperator
Metadata:
  Creation Timestamp:  2021-02-01T04:28:34Z
  Generation:          1
  Managed Fields:
    API Version:  config.openshift.io/v1
    Fields Type:  FieldsV1
    fieldsV1:
      f:metadata:
        f:annotations:
          .:
          f:include.release.openshift.io/ibm-cloud-managed:
          f:include.release.openshift.io/self-managed-high-availability:
          f:include.release.openshift.io/single-node-developer:
      f:spec:
      f:status:
        .:
        f:extension:
    Manager:      cluster-version-operator
    Operation:    Update
    Time:         2021-02-01T04:28:34Z
    API Version:  config.openshift.io/v1
    Fields Type:  FieldsV1
    fieldsV1:
      f:status:
        f:conditions:
        f:relatedObjects:
        f:versions:
    Manager:         cluster-storage-operator
    Operation:       Update
    Time:            2021-02-01T04:36:19Z
  Resource Version:  84368
  Self Link:         /apis/config.openshift.io/v1/clusteroperators/storage
  UID:               874c6446-7ebf-4d89-9bb8-28739f5e84aa
Spec:
Status:
  Conditions:
    Last Transition Time:  2021-02-01T04:36:20Z
    Message:               OpenStackCinderCSIDriverOperatorCRDegraded: All is well
ManilaCSIDriverOperatorCRDegraded: All is well
    Reason:                AsExpected
    Status:                False
    Type:                  Degraded
    Last Transition Time:  2021-02-01T07:13:01Z
    Message:               OpenStackCinderCSIDriverOperatorCRProgressing: All is well
ManilaCSIDriverOperatorCRProgressing: All is well
    Reason:                AsExpected
    Status:                False
    Type:                  Progressing
    Last Transition Time:  2021-02-01T05:19:58Z
    Message:               OpenStackCinderCSIDriverOperatorCRAvailable: All is well
ManilaCSIDriverOperatorCRAvailable: All is well
    Reason:                AsExpected
    Status:                True
    Type:                  Available
    Last Transition Time:  2021-02-01T04:36:48Z
    Message:               All is well
    Reason:                AsExpected
    Status:                True
    Type:                  Upgradeable
  Extension:               <nil>
  Related Objects:
    Group:     
    Name:      openshift-cluster-storage-operator
    Resource:  namespaces
    Group:     
    Name:      openshift-cluster-csi-drivers
    Resource:  namespaces
    Group:     
    Name:      openshift-manila-csi-driver
    Resource:  namespaces
    Group:     operator.openshift.io
    Name:      cluster
    Resource:  storages
    Group:     operator.openshift.io
    Name:      ebs.csi.aws.com
    Resource:  clustercsidrivers
    Group:     operator.openshift.io
    Name:      cinder.csi.openstack.org
    Resource:  clustercsidrivers
    Group:     operator.openshift.io
    Name:      pd.csi.storage.gke.io
    Resource:  clustercsidrivers
    Group:     operator.openshift.io
    Name:      csi.ovirt.org
    Resource:  clustercsidrivers
    Group:     operator.openshift.io
    Name:      manila.csi.openstack.org
    Resource:  clustercsidrivers
  Versions:
    Name:     operator
    Version:  4.7.0-0.nightly-2021-01-30-104433
    Name:     OpenStackCinderCSIDriverOperator
    Version:  4.7.0-0.nightly-2021-01-30-104433
    Name:     ManilaCSIDriverOperator
    Version:  4.7.0-0.nightly-2021-01-30-104433
Events:       <none>

Comment 6 errata-xmlrpc 2021-02-24 15:57:05 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory (Moderate: OpenShift Container Platform 4.7.0 security, bug fix, and enhancement update), and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://access.redhat.com/errata/RHSA-2020:5633