Van: libvirt-users-bounces@redhat.com [mailto:libvirt-users-bounces@redhat.com] Namens Firat KÜÇÜK
Verzonden: donderdag 17 maart 2016 15:58
Aan: libvirt-users@redhat.com
Onderwerp: [libvirt-users] share nothing live migration causes read only filesystem

 

Hello,

I started live migration job for a guest with the following command:

virsh migrate --live --domain my-guest --verbose --persistent --copy-storage-all --desturi qemu+ssh://root@my-otherhost/system


Guest system disk cache mode is none:

    <disk type='file' device='disk'>
      <driver name='qemu' type='qcow2' cache='none'/>
      <source file='/opt/datastore/bulutkare-1118.img'/>
      <backingStore/>
      <target dev='vda' bus='virtio'/>
      <alias name='virtio-disk0'/>
      <address type='pci' domain='0x0000' bus='0x00' slot='0x04' function='0x0'/>
    </disk>
 
 
I think virsh will do a bitewise copy of the content of the disk and creates a .qcow2 file without backing store on the target. (please check with qemu-img info on the destination file)
 
Your guest thinks something is wrong because the hypervisor still has the backingstore description in its xml. That’s why the guest go’s in to failsafe mode and remount’s the root file system as read-only.
 
I think you can fix this by creating an separate xml file without the backing store description and use the option --xml in the virsh migrate command…
 
 
 

after live migration completed, filesystem blocked write operations.

root@my-guest:~/tmp# touch hello
touch: cannot touch ‘hello’: Read-only file system


What can be the reason? What is the best of migrating a VM to a target machine?

Additional info:
Guest operating system is Ubuntu 14.04 x64
Source/Target Host operating system is Ubuntu 15.04 x64
Guest file system is ext4 + swap
Source/Target Host file system is XFS
Source/Target Qemu version 1.2.2
Source/Target libvirt 1.2.12

This is from target libvirt log. It can be important:
/build/qemu-Bjjgxn/qemu-2.2+dfsg/nbd.c:nbd_co_receive_request():L1146: reading from socket failed