Bug 2001924 - [MTC] "Stage" and "Cutover" options are not disabled when a PVC conflict happens
Summary: [MTC] "Stage" and "Cutover" options are not disabled when a PVC conflict happens
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Migration Toolkit for Containers
Classification: Red Hat
Component: General
Version: 1.6.0
Hardware: Unspecified
OS: Unspecified
high
low
Target Milestone: ---
: 1.7.0
Assignee: Mike Turley
QA Contact: Xin jiang
Avital Pinnick
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2021-09-07 13:16 UTC by Sergio
Modified: 2022-03-24 06:32 UTC (History)
6 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2022-03-24 06:32:26 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHBA-2022:1043 0 None None None 2022-03-24 06:32:38 UTC

Description Sergio 2021-09-07 13:16:23 UTC
Description of problem:
When a migration plan has a PVC conflict, the "Stage" and "Cutover" options should be disabled, but they are not.


Version-Release number of selected component (if applicable):
SOURCE CLUSTER: AWS OCP 3.11 (MTC 1.5.1) NFS
TARGET CLUSTER: AWS OCP 4.9 (MTC 1.6.0) OCS4

How reproducible:
Always

Steps to Reproduce:
1. Create an namespace with a pvc and a pod mounting the pvc

$ oc new-project ocp-44516-statewarning-ns

$ cat <<EOF | oc create -f -
apiVersion: v1
kind: PersistentVolumeClaim
metadata:
  namespace: ocp-44516-statewarning-ns
  name: test-data
spec:
  accessModes:
  - ReadWriteOnce
  resources:
    requests:
      storage: 1Gi
EOF

$ cat <<EOF | oc create -f -
apiVersion:  apps/v1
kind: Deployment
metadata:
  labels:
    app: state-warning-test
  name: state-warning-test
  namespace: ocp-44516-statewarning-ns
spec:
  replicas:  1
  selector:
    matchLabels:
      app: resize-test
  template:
    metadata:
      labels:
        app: resize-test
    spec:
      containers:
      - name: podtest
        imagePullPolicy: Always
        image: quay.io/openshifttest/alpine
        command: [ "/bin/sh", "-c", "--" ]
        args:
        - while true; do sleep 30; done;
        restartPolicy: Never
        volumeMounts:
        - name: testvolume
          mountPath: /data/test
      volumes:
      - name: testvolume
        persistentVolumeClaim:
          claimName: test-data
EOF


2. Create an intra-cluster migration plan.

From source cluster to source cluster, no namespaces mapping.


Actual results:

The migplan is reporting the conflic

 - category: Warn
    lastTransitionTime: "2021-09-07T12:05:14Z"
    message: Source PVCs [ocp-44516-statewarning-ns/test-data] are mapped to destination PVCs which result in conflicts. Please map each source PVC to a distinct destination PVC before running a State Migration.
    reason: NotDistinct
    status: "True"
    type: PvNameConflict

But in the UI the kebab options "Stage" and "Cutover" are not disabled.

Expected results:
The "Stage" and "Cutover" options in the kebab should be disabled.

Additional info:

Comment 1 Ian 2021-09-10 16:21:07 UTC
https://github.com/konveyor/mig-ui/pull/1323 This bug should be fixed -

Comment 7 errata-xmlrpc 2022-03-24 06:32:26 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 (Migration Toolkit for Containers (MTC) 1.7.0 release advisory), 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/RHBA-2022:1043


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