Bug 2173742 - Creating DPA resource fails on OCP 4.6 clusters
Summary: Creating DPA resource fails on OCP 4.6 clusters
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Migration Toolkit for Containers
Classification: Red Hat
Component: Controller
Version: 1.7.8
Hardware: Unspecified
OS: Unspecified
unspecified
high
Target Milestone: ---
: 1.7.8
Assignee: Dylan Murray
QA Contact: mohamed
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2023-02-27 20:36 UTC by mohamed
Modified: 2023-03-23 02:17 UTC (History)
2 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2023-03-23 02:16:45 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHSA-2023:1428 0 None None None 2023-03-23 02:17:05 UTC

Description mohamed 2023-02-27 20:36:30 UTC
Description of problem:

When deploying MTC on a OCP 4.6 cluster, the DPA fails to get created according to the logs, which results in some pods being missing. 

From the logs in the migration-controller in the OCP 4.6 cluster it indicates that an unexpected null value is passed which causes the error.


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

MTC 1.7.8
OADP 1.0.8
OCP 4.6 --> OCP 4.10


How reproducible:
Always

Steps to Reproduce:
1. Provision a pair of clusters where one of them is OCP 4.6
2. Deploy mtc application


Actual results:

Actual resources DPA resource is not created


Expected results:

The MTC should be installed along with OADP and all their resources without any errors


Additional info:

This behavior is observed only on 4.6 clusters

When creating a DPA resource in the UI console, the resource is not created but the 
pods are created and running, and shows the error message ( see attached image )


from the logs:

 lastTransitionTime: "2023-02-27T12:44:08Z"
      message: 'Failed to create object: b''{"kind":"Status","apiVersion":"v1","metadata":{},"status":"Failure","message":"DataProtectionApplication.oadp.openshift.io
        \\"velero\\" is invalid: [spec.unsupportedOverrides.awsPluginImageFqin: Invalid
        value: \\"null\\": spec.unsupportedOverrides.awsPluginImageFqin in body must
        be of type string: \\"null\\", spec.unsupportedOverrides.azurePluginImageFqin:
        Invalid value: \\"null\\": spec.unsupportedOverrides.azurePluginImageFqin
        in body must be of type string: \\"null\\", spec.unsupportedOverrides.gcpPluginImageFqin:
        Invalid value: \\"null\\": spec.unsupportedOverrides.gcpPluginImageFqin in
        body must be of type string: \\"null\\", spec.unsupportedOverrides.openshiftPluginImageFqin:
        Invalid value: \\"null\\": spec.unsupportedOverrides.openshiftPluginImageFqin
        in body must be of type string: \\"null\\", spec.unsupportedOverrides.resticRestoreImageFqin:
        Invalid value: \\"null\\": spec.unsupportedOverrides.resticRestoreImageFqin
        in body must be of type string: \\"null\\", spec.unsupportedOverrides.veleroImageFqin:
        Invalid value: \\"null\\": spec.unsupportedOverrides.veleroImageFqin in body
        must be of type string: \\"null\\", spec.configuration.velero.logLevel: Invalid
        value: \\"null\\": spec.configuration.velero.logLevel in body must be of type
        string: \\"null\\", spec.configuration.velero.logLevel: Unsupported value:
        \\"null\\": supported values: \\"trace\\", \\"debug\\", \\"info\\", \\"warning\\",
        \\"error\\", \\"fatal\\", \\"panic\\"]","reason":"Invalid","details":{"name":"velero","group":"oadp.openshift.io","kind":"DataProtectionApplication","causes":[{"reason":"FieldValueInvalid","message":"Invalid
        value: \\"null\\": spec.unsupportedOverrides.awsPluginImageFqin in body must
        be of type string: \\"null\\"","field":"spec.unsupportedOverrides.awsPluginImageFqin"},{"reason":"FieldValueInvalid","message":"Invalid
        value: \\"null\\": spec.unsupportedOverrides.azurePluginImageFqin in body
        must be of type string: \\"null\\"","field":"spec.unsupportedOverrides.azurePluginImageFqin"},{"reason":"FieldValueInvalid","message":"Invalid
        value: \\"null\\": spec.unsupportedOverrides.gcpPluginImageFqin in body must
        be of type string: \\"null\\"","field":"spec.unsupportedOverrides.gcpPluginImageFqin"},{"reason":"FieldValueInvalid","message":"Invalid
        value: \\"null\\": spec.unsupportedOverrides.openshiftPluginImageFqin in body
        must be of type string: \\"null\\"","field":"spec.unsupportedOverrides.openshiftPluginImageFqin"},{"reason":"FieldValueInvalid","message":"Invalid
        value: \\"null\\": spec.unsupportedOverrides.resticRestoreImageFqin in body
        must be of type string: \\"null\\"","field":"spec.unsupportedOverrides.resticRestoreImageFqin"},{"reason":"FieldValueInvalid","message":"Invalid
        value: \\"null\\": spec.unsupportedOverrides.veleroImageFqin in body must
        be of type string: \\"null\\"","field":"spec.unsupportedOverrides.veleroImageFqin"},{"reason":"FieldValueInvalid","message":"Invalid
        value: \\"null\\": spec.configuration.velero.logLevel in body must be of type
        string: \\"null\\"","field":"spec.configuration.velero.logLevel"},{"reason":"FieldValueNotSupported","message":"Unsupported
        value: \\"null\\": supported values: \\"trace\\", \\"debug\\", \\"info\\",
        \\"warning\\", \\"error\\", \\"fatal\\", \\"panic\\"","field":"spec.configuration.velero.logLevel"}]},"code":422}\n'''
      reason: Failed
      status: "True"
      type: Failure

Comment 2 Dylan Murray 2023-02-27 20:56:28 UTC
Looks like a bug as a result of https://github.com/migtools/mig-operator/pull/861/files

Imagine we need to simply not set the spec fields if the var is undefined.

Comment 3 Dylan Murray 2023-02-27 21:31:13 UTC
Above comment was incorrect... `null` is intentional in case a user sets it and removes it. Investigating different options to allow this to work.

Comment 4 Dylan Murray 2023-02-27 21:58:29 UTC
https://github.com/migtools/mig-operator/pull/871

Comment 5 Dylan Murray 2023-02-27 22:05:59 UTC
CP PR: https://github.com/migtools/mig-operator/pull/872

Comment 9 mohamed 2023-03-01 19:35:47 UTC
Verified using MTC prestage

Comment 13 errata-xmlrpc 2023-03-23 02:16:45 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 (Important: Migration Toolkit for Containers (MTC) 1.7.8 security and bug fix 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-2023:1428


Note You need to log in before you can comment on or make changes to this bug.