Description of problem: mig-operator is failing to create a DPA CR in OCP 4.6 cluster. See below logs for more details. fatal: [localhost]: FAILED! => {"changed": false, "error": 422, "msg": "Failed to create object: b'{\"kind\":\"Status\",\"apiVersion\":\"v1\",\"metadata\":{},\"status\":\"Failure\",\"message\":\"DataProtectionApplication.oadp.openshift.io \\\\\"velero\\\\\" is invalid: [spec.configuration.velero.podConfig.resourceAllocations.requests.memory: Invalid value: \\\\\"null\\\\\": spec.configuration.velero.podConfig.resourceAllocations.requests.memory in body must be of type integer,string: \\\\\"null\\\\\", spec.configuration.velero.podConfig.resourceAllocations.limits: Invalid value: \\\\\"null\\\\\": spec.configuration.velero.podConfig.resourceAllocations.limits in body must be of type object: \\\\\"null\\\\\", spec.configuration.restic.podConfig.resourceAllocations.limits: Invalid value: \\\\\"null\\\\\": spec.configuration.restic.podConfig.resourceAllocations.limits in body must be of type object: \\\\\"null\\\\\", spec.configuration.restic.podConfig.resourceAllocations.requests.memory: Invalid value: \\\\\"null\\\\\": spec.configuration.restic.podConfig.resourceAllocations.requests.memory in body must be of type integer,string: \\\\\"null\\\\\"]\",\"reason\":\"Invalid\",\"details\":{\"name\":\"velero\",\"group\":\"oadp.openshift.io\",\"kind\":\"DataProtectionApplication\",\"causes\":[{\"reason\":\"FieldValueInvalid\",\"message\":\"Invalid value: \\\\\"null\\\\\": spec.configuration.velero.podConfig.resourceAllocations.requests.memory in body must be of type integer,string: \\\\\"null\\\\\"\",\"field\":\"spec.configuration.velero.podConfig.resourceAllocations.requests.memory\"},{\"reason\":\"FieldValueInvalid\",\"message\":\"Invalid value: \\\\\"null\\\\\": spec.configuration.velero.podConfig.resourceAllocations.limits in body must be of type object: \\\\\"null\\\\\"\",\"field\":\"spec.configuration.velero.podConfig.resourceAllocations.limits\"},{\"reason\":\"FieldValueInvalid\",\"message\":\"Invalid value: \\\\\"null\\\\\": spec.configuration.restic.podConfig.resourceAllocations.limits in body must be of type object: \\\\\"null\\\\\"\",\"field\":\"spec.configuration.restic.podConfig.resourceAllocations.limits\"},{\"reason\":\"FieldValueInvalid\",\"message\":\"Invalid value: \\\\\"null\\\\\": spec.configuration.restic.podConfig.resourceAllocations.requests.memory in body must be of type integer,string: \\\\\"null\\\\\"\",\"field\":\"spec.configuration.restic.podConfig.resourceAllocations.requests.memory\"}]},\"code\":422}\\n'", "reason": "Unprocessable Entity", "status": 422} Version-Release number of selected component (if applicable): OCP 4.6 How reproducible: Always Steps to Reproduce: 1. Install MTC operator Actual results: mig-operator is failing to create a DPA CR due to null value being passed instead of int. Expected results: DPA resource should get created successfully. Additional info:
Jason was able to repair this in OADP by adding "nullabe: true" to the fields in the CRD. We're unsure why this works on 4.10 compared to 4.6, but this would ultimately be an OADP change to fix. Discussing with Dylan about the right way to approach this. It's possible this is something added to OADP 1.0.3.
This issue actually requires a fix in OADP CRDs. This is a tracking BZ for the OADP bug. The JIRA is linked to the BZ.
Verified with MTC 1.7.2 (Prestage) metadata_nvr: openshift-migration-operator-metadata-container-v1.7.2-15 No issue found in operator pod logs. Also verified on OCP 4.9 $ oc version Client Version: 4.7.19 Server Version: 4.6.0-0.nightly-2022-06-17-174132 Kubernetes Version: v1.19.16+8203b20 $ oc logs -n openshift-migration migration-operator-6ddb7575c-stqqh PLAY RECAP ********************************************************************* localhost : ok=35 changed=1 unreachable=0 failed=0 skipped=39 rescued=0 ignored=0 Moving to Verified status.
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: Migration Toolkit for Containers (MTC) 1.7.2 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-2022:5483