Uploaded image for project: 'Migration Toolkit for Virtualization'
  1. Migration Toolkit for Virtualization
  2. MTV-3509

[CCLM] Migration stuck for VM with directly attached PVC

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Unresolved
    • Icon: Major Major
    • 2.10.0
    • 2.10.0
    • Controller
    • None
    • Important

      Description of problem:

      Migration stuck for VM with  directly attached PVC

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

      CNV v4.20.0-180 

      How reproducible:

      Always

      Steps to Reproduce:

      1. Create the VM with a PVC attached. 
      ---
      apiVersion: kubevirt.io/v1
      kind: VirtualMachine
      metadata:
        labels:
          kubevirt.io/vm: vm-cirros
        name: vm-cirros
      spec:
        runStrategy: Halted
        template:
          metadata:
            labels:
              kubevirt.io/vm: vm-cirros
          spec:
            domain:
              devices:
                disks:
                - disk:
                    bus: virtio
                  name: disk1
                - disk:
                    bus: virtio
                  name: cloudinitdisk
              memory:
                guest: 128Mi
              resources: {}
            terminationGracePeriodSeconds: 0
            volumes:
            - persistentVolumeClaim:
                claimName: pvc1
              name: disk1 
            - cloudInitNoCloud:
                userData: |
                  #!/bin/sh
      
      
                  echo 'printed from cloud-init userdata'
              name: cloudinitdisk 
      2. Start the VM
      3. Create a Migration Plan by MTV
      4. Migrate the vm to another cluster

      Actual results:

      Migration stuck for VM with directly attached PVC, the target VM is not ready due to ErrorPvcNotFound.
      On target cluster:
      
      $ oc get vmim -w
      NAME             PHASE   VMI
      forklift-zt7zl           vm-cirros
      forklift-zt7zl           vm-cirros
      forklift-zt7zl   WaitingForSync   vm-cirros
      forklift-zt7zl   WaitingForSync   vm-cirros
      forklift-zt7zl   Pending          vm-cirros
      
      $ oc get vm
      NAME        AGE     STATUS             READY
      vm-cirros   2m39s   ErrorPvcNotFound   False
      
      On the source cluster:
      $ oc get vmim -w
      NAME             PHASE   VMI
      forklift-gp54q           vm-cirros
      forklift-gp54q           vm-cirros
      forklift-gp54q   Synchronizing   vm-cirros
      forklift-gp54q   Pending         vm-cirros
      forklift-gp54q   Scheduling      vm-cirros
      forklift-gp54q   Scheduling      vm-cirros

      Expected results:

      VM with directly PVC attached should be able to migrate sucessfully

      Additional info:

       

        1. source_pv.yaml
          2 kB
        2. source_pvc.yaml
          2 kB
        3. source_vm.yaml
          2 kB
        4. target_pv.yaml
          2 kB
        5. target_pvc.yaml
          2 kB
        6. target_vm.yaml
          2 kB

              slucidi@redhat.com Samuel Lucidi
              yadu1@redhat.com Yan Du
              Yan Du Yan Du
              Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

                Created:
                Updated: