vzrestore too an existing directory

gillesMo

New Member
Mar 29, 2010
27
0
1
I'm exploring the capabilities before moving some VMs to OpenVZ containers with Proxmox.
I use a FC SAN Array.

In a way, to mimic what I did with VMware Server, I'm using a different LUN/VG/LV/FS for each container (/var/lib/vz/private/$CID).

I think it can be usefull for these reasons :
- Easily relocate a container to another server, without copying the data other the LAN
- See I/O stats by VM (I use cacti and can see the disk usage and I/O stats provided by net-snmp)
- LVM snapshots for backups are not filed by other containers' activity

I have to wait for a second server to test migrations, so I don't know if it will work.
I understand the difference betxeen a shared storage KVM VM and my config.
I don't have shared storage with OpenVZ, and I must allocate the same space (LUN/VG/LV/FS) on all the servers I want my containers to be able to migrate...

For now, one thing does not work, and I think it could : vzretore.
I tried to clone a container using vzdump/vrestore, but vzrestore does not want to restore in an existing directory in vz/private and vz/root...
As my SAN volume is mounted on the private/$VID of my containers, it must pre-exist if I want the restore inside my SAN volume...

Is there any reason I can't force vzretore ? Perhaps a simple -f option ?
 
I think it can be usefull for these reasons :

We already offered to implement that to the OpenVZ team, but they told us that they are not interested in that feature (because there is no interest from there customers).
 
Of course I know that.
OpenVZ does not have to know it is on a SAN.
Debian, proxmox are not supported by my hardware vendors, but as they work, I use them !

By the way, even without SAN, if I want to use one LV by container, the problem will be the same, the private directory will have exist for a vzrestore...
 
Vzrestore is a simple perl script, so I have have hacked it.
I have commented out the test on the private dir, and it works fine.

Who is the upstream developper team for vzdump ? Proxmox, OpenVZ, Parallels ?
I see references to Proxmox on the OpenVZ wiki...

If the force option works, it doesn't hurt anyone to implement it, no ?