[pve-devel] [PATCH] Add copy_disk and change_disk command

Serge NOEL serge.noel2008 at gmail.com
Fri May 22 19:05:18 CEST 2015


First : the reason

With this solution, what take in account in the minimal time to recover, 
as we can start with the copy.

Perhaps i made some mistakes, but i think that with your solution, it 
will take time to recover because NAS are less powerfull as Disk Bay (SAN)

Backup is made like this :

  * Backup of servers thru Proxmox system on a share (vzdump)
  * Backup of the share (vzdumps) on a tape
  * New one wanted : Backup by copying disk from SAN to NAS

In a 'conventionnal' solution, in case of SAN failure, we have to 
restore data on NAS (used as SAN but with less power), to gain time on 
restore, we plan to use copy, and copy should be part of backup.
That's the reason of my research. We will not bypass 'conventionnal' backup.

I know that a lvm snapshot is another way to do that. But in this case, 
it must be between 2 lvm.

I have seen lvmsync wich permit to make snapshot (from lvm), and 
transfert only deltas between storages, that could be great, but for 
now, i don't understand really how to implement this.

Documentation says :

  * do a full copy between 2 lvm (on different machines) with dd
  * configure snapshot on source lvm
  * and then launch lvmsync to reproduce modifications from source lvm
    to destination


a kind of rsync, but without the need of scanning both lvm. Of course, 
that's the more powerfull. But as far as i know, it needs room on 
initial disk and i don't know howto estimate it. Furthermore it needs 
some room (to store snapshot), and disk bay of my client is full.

Second : way to do that
you say :

    Second, I guess you could add an option to move_disk which avoids
    changing the config. Changing the config can be done with other
    API calls (remove/add disk).

that exactly what i want, but i don't have sufficient experience with 
perl programming to do that, so it's more easy for me to copy/paste like 
i do

Serge

Le 22/05/2015 18:30, Dietmar Maurer a écrit :
>> Splitting move_disk : what i have done is a copy/paste of move_disk and
>> then remove uneeded lines. If we cut move_disk (move_disk will then
>> launch copy_disk and change_disk) we will avoid to do a copy/paste wich
>> is allways a bad way of coding.
>>
>> So i will try to rewrite move_disk to allow splitting it in 2 parts, one
>> will copy disk and the second one will change Proxmox config.
>>
>> move_disk we become a call to those 2 new functions.
>>
>> What are you thinking about that ?
> First, I am not really convinced  - You want only use that make VM backups?
>
> I am asking because this does not have snapshot semantics if you have more
> that one disk. Also, on a reasonable storage, you can simply make a snapshot,
> which is much faster as easier to manage.
>
> There are so many options when people talk about backups, so I want to
> make sure I understand your needs.

> Second, I guess you could add an option to move_disk which avoids
> changing the config. Changing the config can be done with other
> API calls (remove/add disk).
>

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.proxmox.com/pipermail/pve-devel/attachments/20150522/18fb0983/attachment.htm>


More information about the pve-devel mailing list