Skip to content

feat: change volume migration procedure

Josef Smrčka requested to merge jsmrcka-migrations into master

Refactor volume migration.

Split the volume migration into 2 separate steps:

  • step1: create snapshot of source volume
  • step2: clone snapshot + flatten clone + copy clone to destination volume

Introduce a parameter which configures, whether step2 is done while the VM is off.

Original (non-default) flow:

  1. shutoff source VM
  2. perform step1 + step2 (originally not split)
  3. start source VM
  4. ...

New default flow:

  1. shutoff source VM
  2. perform step1
  3. start source VM
  4. perform step2
  5. ...

Rationale: There is no reason to keep the source VM off once the snapshot is created. The VM is started after the migration anyway, so the source and destination volumes will diverge eventually. The new default approach aims to reduce the time the VM is off.

Edited by Josef Smrčka

Merge request reports