Error migrating VM (using LVM storages)

jmjosebest

Renowned Member
Jan 16, 2009
192
36
93
Hi,

I want migrate a KVM from one node to other one.
The KVM has 1 storage in a LVM unit.
The same LVM exist in the destination node and is free of space.
But Proxmox only migrates the config file, the RAW image has not migrated.

Code:
Jan 23 18:53:10 starting migration of VM 104 to node 'pveabs1' (5.134.112.xxx)
Jan 23 18:53:10 copying disk images
Jan 23 18:53:11 migration finished successfuly (duration 00:00:01)
TASK OK
 
post your /etc/pve/storage.cfg
 
post your /etc/pve/storage.cfg

The KVM is in "lvm: ssd480g2", in pveabs1 is empty

I want migrate from pveabs3 to pveabs1

Code:
root@pveabs3:~# cat /etc/pve/storage.cfg
        nfs: nfsabs1-private
        path /mnt/pve/nfsabs1-private
        server 192.168.1.10
        export /raid5
        options vers=3
        content images,iso,vztmpl,rootdir,backup
        maxfiles 4


dir: local
        path /var/lib/vz
        content images,iso,vztmpl,rootdir
        maxfiles 0


nfs: nfsabs1-public
        path /mnt/pve/nfsabs1-public
        server 5.134.112.xxx
        export /raid5
        options vers=3
        content images,iso,vztmpl,rootdir,backup
        maxfiles 4


dir: ssd2
        path /ssd2
        content images,rootdir
        maxfiles 0
        nodes pveabs1


dir: sata1
        path /sata1
        content images
        maxfiles 0
        nodes pveabs1


lvm: ssd480g1
        vgname ssd2
        shared
        content images
        nodes pveabs2,pveabs3


lvm: ssd480g2
        vgname ssd3
        shared
        content images
        nodes pveabs2,pveabs3,pveabs1


lvm: LVMLocalSATA
        vgname sata1
        shared
        content images


root@pveabs3:~#
 
Last edited:
Now, I have removed the "shared" tag in the storage "ssd480g2"
and this is the error:

Code:
Jan 24 01:23:52 starting migration of VM 104 to node 'pveabs1' (5.134.112.201)
Jan 24 01:23:52 copying disk images
Jan 24 01:23:52 ERROR: Failed to sync data - can't migrate 'ssd480g2:vm-104-disk-1' - storagy type 'lvm' not supported
Jan 24 01:23:52 aborting phase 1 - cleanup resources
Jan 24 01:23:52 ERROR: migration aborted (duration 00:00:10): Failed to sync data - can't migrate 'ssd480g2:vm-104-disk-1' - storagy type 'lvm' not supported
TASK ERROR: migration aborted
 
Output of pvscan and lvscan on pveabs1?


Code:
root@pveabs1:~# pvscan
  PV /dev/sdd1   VG sata1   lvm2 [931.51 GiB / 31.51 GiB free]
  PV /dev/sdc1   VG ssd3    lvm2 [447.13 GiB / 447.13 GiB free]
  PV /dev/sdb1   VG ssd2    lvm2 [111.79 GiB / 1.79 GiB free]
  PV /dev/sda2   VG pve     lvm2 [111.29 GiB / 13.87 GiB free]
  Total: 4 [1.56 TiB] / in use: 4 [1.56 TiB] / in no VG: 0 [0   ]
root@pveabs1:~#
root@pveabs1:~#
root@pveabs1:~# lvscan
  ACTIVE            '/dev/sata1/sata1' [900.00 GiB] inherit
  ACTIVE            '/dev/ssd2/ssd2' [110.00 GiB] inherit
  ACTIVE            '/dev/pve/swap' [7.00 GiB] inherit
  ACTIVE            '/dev/pve/root' [27.75 GiB] inherit
  ACTIVE            '/dev/pve/data' [62.67 GiB] inherit
root@pveabs1:~#
root@pveabs1:~#
root@pveabs1:~# vgdisplay ssd3
  --- Volume group ---
  VG Name               ssd3
  System ID
  Format                lvm2
  Metadata Areas        1
  Metadata Sequence No  3
  VG Access             read/write
  VG Status             resizable
  MAX LV                0
  Cur LV                0
  Open LV               0
  Max PV                0
  Cur PV                1
  Act PV                1
  VG Size               447.13 GiB
  PE Size               512.00 KiB
  Total PE              915718
  Alloc PE / Size       0 / 0
  Free  PE / Size       915718 / 447.13 GiB
  VG UUID               s4YajP-njCO-0qpv-Q2RR-0pry-lk1A-cg0aJj
 
I've do a backup, and I get error in the restore process.

Is the KVM 104 and in the restore process I set as 150.

Code:
extracting archive '/mnt/pve/nfsabs1-private/dump/vzdump-qemu-104-2013_01_24-01_28_26.tar.lzo'
extracting 'qemu-server.conf' from archive
extracting 'vm-disk-virtio0.raw' from archive
  /dev/ssd3/vm-150-disk-1: not found: device not cleared
lvcreate 'ssd3/pve-vm-150' error:   Aborting. Failed to wipe start of new LV.
tar: vm-disk-virtio0.raw: Cannot write: Broken pipe
tar: 68613: Child returned status 5
tar: Exiting with failure status due to previous errors
starting cleanup
TASK ERROR: command 'zcat -f|tar xf /mnt/pve/nfsabs1-private/dump/vzdump-qemu-104-2013_01_24-01_28_26.tar.lzo '--to-command=/usr/lib/qemu-server/qmextract --storage ssd480g2'' failed: exit code 2
 
Last edited:
Whell. I have restarted the pveabs1 node and now seems the restore process has started Ok

Code:
extracting archive '/mnt/pve/nfsabs1-private/dump/vzdump-qemu-104-2013_01_24-01_28_26.tar.lzo'
extracting 'qemu-server.conf' from archive
extracting 'vm-disk-virtio0.raw' from archive
  Logical volume "vm-150-disk-1" created
new volume ID is 'ssd480g2:vm-150-disk-1'
restore data to '/dev/ssd3/vm-150-disk-1' (450971566080 bytes)

doing...
 

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!