Migration problem

bemar

Member
Nov 16, 2011
69
0
6
Switzerland
Hello,

I wan't to make migration tests of KVM Machines.
The machine I wan't to migrate was created on vmhost1. The machine is running well on this host.

But Online or Offline Migration to vmhost2 fails with error:
PHP:
Apr 17 11:14:55 starting migration of VM 102 to node 'vmhost2' (192.168.61.9)
Apr 17 11:14:55 copying disk images
Apr 17 11:14:55 starting VM 102 on remote node 'vmhost2'
Apr  17 11:14:56 ERROR: online migrate failure - command '/usr/bin/ssh -c  blowfish -o 'BatchMode=yes' root@192.168.61.9 qm start 102 --stateuri  tcp --skiplock' failed: exit code 255
Apr 17 11:14:57 ERROR: migration finished with problems (duration 00:00:03)
TASK ERROR: migration problems

Both machines have the same software version (2.0-59/18400f07)

All storages are identically created on the machines (iscsi, nfs)

After the machine is migrated to vmhost2 the machine is offline and starting the machine fails with error:
PHP:
Could not access KVM kernel module: No such file or directory
failed to initialize KVM: No such file or directory
No accelerator found!
TASK  ERROR: start failed: command '/usr/bin/kvm -id 102 -chardev  'socket,id=monitor,path=/var/run/qemu-server/102.mon,server,nowait' -mon  'chardev=monitor,mode=readline' -vnc  unix:/var/run/qemu-server/102.vnc,x509,password -pidfile  /var/run/qemu-server/102.pid -daemonize -incoming tcp:localhost:60000  -usbdevice tablet -name ContinuumV7 -smp 'sockets=2,cores=4' -nodefaults  -boot 'menu=on' -vga cirrus -k de-ch -drive  'if=none,id=drive-ide2,media=cdrom,aio=native' -device  'ide-cd,bus=ide.1,unit=0,drive=drive-ide2,id=ide2,bootindex=200' -drive  'file=/dev/lvm.iscsi.lun0/vm-102-disk-1,if=none,id=drive-virtio0,aio=native,cache=none'  -device  'virtio-blk-pci,drive=drive-virtio0,id=virtio0,bus=pci.0,addr=0xa,bootindex=100'  -m 4096 -netdev  'type=tap,id=net0,ifname=tap102i0,script=/var/lib/qemu-server/pve-bridge'  -device  'rtl8139,mac=22:07:87:17:F4D,netdev=net0,bus=pci.0,addr=0x12,id=net0,bootindex=300''  failed: exit code 1

Any ideas?

Thx and best regards

Benjamin
 
please post /etc/pve/storage.cfg and 102.conf.
 
Ok. I think I was to fast with that statement.

OpenVZ Containers with NFS have problems:

PHP:
Apr 17 12:02:15 starting migration of CT 100 to node 'vmhost1' (192.168.61.8)
Apr 17 12:02:15 container is running - using online migration
Apr 17 12:02:15 container data is on shared storage 'NFSData'
Apr 17 12:02:15 start live migration - suspending container
Apr 17 12:02:18 # vzctl --skiplock chkpnt 100 --suspend
Apr 17 12:02:15 Setting up checkpoint...
Apr 17 12:02:15     suspend...
Apr 17 12:02:18 Can not suspend container: Resource temporarily unavailable
Apr 17 12:02:18 Error: foreign process 808/3283(vzctl) inside CT (e.g. vzctl enter or vzctl exec).
Apr 17 12:02:18 Error: suspend is impossible now.
Apr 17 12:02:18 Error: foreign process 808/3283(vzctl) inside CT (e.g. vzctl enter or vzctl exec).
Apr 17 12:02:18 Error: suspend is impossible now.
Apr 17 12:02:18 Error: foreign process 808/3283(vzctl) inside CT (e.g. vzctl enter or vzctl exec).
Apr 17 12:02:18 Error: suspend is impossible now.
Apr 17 12:02:18 ERROR: Failed to suspend container: Checkpointing failed
Apr 17 12:02:18 aborting phase 1 - cleanup resources
Apr 17 12:02:18 start final cleanup
Apr 17 12:02:18 ERROR: migration aborted (duration 00:00:04): Failed to suspend container: Checkpointing failed
TASK ERROR: migration aborted



/etc/pve/storage.cfg (vmhost1 and vmhost2 identically)
PHP:
dir: local
        path /var/lib/vz
        shared
        content images,iso,vztmpl,backup,rootdir
        maxfiles 0

nfs: NFSData
        path /mnt/pve/NFSData
        server 172.60.23.3
        export /data
        options vers=3
        content iso,vztmpl,rootdir,backup
        maxfiles 5

iscsi: iscsi.storage.lun1
        portal 172.60.23.3
        target iqn.2012-03.local.finaware.san:storage.lun1
        content none

lvm: lvm.iscsi.lun0
        vgname lvm.iscsi.lun0
        base iscsi.storage.lun1:0.0.0.scsi-14945540000000000ddeb82f433a6f3ccc88c3eb634beb199
        shared
        content images

/etc/pve/nodes/vmhost2/openvz/100.conf
PHP:
ONBOOT="yes"

PHYSPAGES="0:131072"
SWAPPAGES="0:512M"
KMEMSIZE="243269632:268435456"
DCACHESIZE="121634816:134217728"
LOCKEDPAGES="65536"
PRIVVMPAGES="unlimited"
SHMPAGES="unlimited"
NUMPROC="unlimited"
VMGUARPAGES="0:unlimited"
OOMGUARPAGES="0:unlimited"
NUMTCPSOCK="unlimited"
NUMFLOCK="unlimited"
NUMPTY="unlimited"
NUMSIGINFO="unlimited"
TCPSNDBUF="unlimited"
TCPRCVBUF="unlimited"
OTHERSOCKBUF="unlimited"
DGRAMRCVBUF="unlimited"
NUMOTHERSOCK="unlimited"
NUMFILE="unlimited"
NUMIPTENT="unlimited"

# Disk quota parameters (in form of softlimit:hardlimit)
DISKSPACE="2097152:2306867"
DISKINODES="400000:440000"
QUOTATIME="0"
QUOTAUGIDLIMIT="0"

# CPU fair scheduler parameter
CPUUNITS="1000"
CPUS="1"
HOSTNAME="xxxx"
SEARCHDOMAIN="xxxxx"
NAMESERVER="192.168.62.21"
NETIF="ifname=eth0,mac=7E:7B:4E:3C:07:0B,host_ifname=veth100.0,host_mac=E2:AC:60:4B:82:76,bridge=vmbr0"
VE_ROOT="/var/lib/vz/root/$VEID"
VE_PRIVATE="/mnt/pve/NFSData/private/100"
OSTEMPLATE="centos-6-x86.tar.gz"
DESCRIPTION="MMonit Server instanz%0A192.168.65.13%0ACentos 6.2 x86"
 
PHP:
dir: local
        path /var/lib/vz
        shared
        content images,iso,vztmpl,backup,rootdir
        maxfiles 0

you cannot mark /var/lib/vz as "shared". its local storage and not shared, never mark it as shared (unless you know exactly what you are doing).
 
Still not working.

What I have done:
I marked local store as not shared.
No Console is opened.

1. Stopping machine
2. Offline Migration to vmhost1 and back works
3. Starting machine on vmhost1
4. Starting online migration to vmhost2
5. Got Error:

PHP:
Apr 17 14:05:38 starting migration of CT 100 to node 'vmhost2' (192.168.61.9)
Apr 17 14:05:38 container is running - using online migration
Apr 17 14:05:38 container data is on shared storage 'NFSData'
Apr 17 14:05:38 start live migration - suspending container
Apr 17 14:05:38 dump container state
Apr 17 14:05:38 dump 2nd level quota
Apr 17 14:05:40 initialize container on remote node 'vmhost2'
Apr 17 14:05:40 initializing remote quota
Apr 17 14:05:52 turn on remote quota
Apr 17 14:05:52 load 2nd level quota
Apr 17 14:05:52 starting container on remote node 'vmhost2'
Apr 17 14:05:52 restore container state
Apr  17 14:05:54 # /usr/bin/ssh -c blowfish -o 'BatchMode=yes'  root@192.168.61.9 vzctl restore 100 --undump --dumpfile  /mnt/pve/NFSData/dump/dump.100 --skip_arpdetect
Apr 17 14:05:52 Restoring container ...
Apr 17 14:05:52 Starting container ...
Apr 17 14:05:52 Container is mounted
Apr 17 14:05:52 	undump...
Apr 17 14:05:52 Setting CPU units: 1000
Apr 17 14:05:52 Setting CPUs: 1
Apr 17 14:05:52 Configure veth devices: veth100.0 
Apr 17 14:05:52 Adding interface veth100.0 to bridge vmbr0 on CT0 for CT100
Apr 17 14:05:54 vzquota : (warning) Quota is running for id 100 already
Apr 17 14:05:54 Error: undump failed: No such file or directory
Apr 17 14:05:54 Restoring failed:
Apr 17 14:05:54 Error: rst_open_file: failed to lookup path '/tmp/.nfs00000000021809d600000016': -2
Apr 17 14:05:54 Error: can't open file /tmp/.nfs00000000021809d600000016
Apr 17 14:05:54 Error: do_rst_vma: rst_file: 100848
Apr 17 14:05:54 Error: do_rst_mm: failed to restore vma: -2
Apr 17 14:05:54 Error: do_rst_mm 1604440
Apr 17 14:05:54 Error: rst_mm: -2
Apr 17 14:05:54 Error: make_baby: -2
Apr 17 14:05:54 Error: rst_clone_children
Apr 17 14:05:54 Container start failed
Apr  17 14:05:54 ERROR: online migrate failure - Failed to restore  container: Can't umount /var/lib/vz/root/100: Device or resource busy
Apr 17 14:05:54 start final cleanup
Apr 17 14:05:54 ERROR: migration finished with problems (duration 00:00:16)
TASK ERROR: migration problems

Best regards

Ben
 

About

The Proxmox community has been around for many years and offers help and support for Proxmox VE, Proxmox Backup Server, and Proxmox Mail Gateway.
We think our community is one of the best thanks to people like you!

Get your subscription!

The Proxmox team works very hard to make sure you are running the best software and getting stable updates and security enhancements, as well as quick enterprise support. Tens of thousands of happy customers have a Proxmox subscription. Get yours easily in our online shop.

Buy now!