On 12/19/18 11:07 AM, Alexandre DERUMIER wrote:
hat do you think about splitting the code path completely from the
current migration path? This would allow us to work on it without any
modification to the current migration code. Makes testing easier and we
can refactor the code later on (and combine common functionality again)
Yes, I can do it if you want.
with a full /usr/share/perl5/PVE/QemuMigrateExternal.pm for example (with all
phases) ?
Should be fine, yes.
----- Mail original -----
De: "David Limbeck" <d.limb...@proxmox.com>
À: "pve-devel" <pve-devel@pve.proxmox.com>
Envoyé: Mercredi 19 Décembre 2018 10:32:37
Objet: Re: [pve-devel] [PATCH v3 qemu-server 0/7] online vm migration to
external cluster
What do you think about splitting the code path completely from the
current migration path? This would allow us to work on it without any
modification to the current migration code. Makes testing easier and we
can refactor the code later on (and combine common functionality again)
some more comments follow on the respective patches
On 11/27/18 4:38 PM, Alexandre Derumier wrote:
This add support to migrate a vm online to an different external cluster.
(This a rework of a previous patch series sent 2years ago)
qm migrate_external <vmid> <targetremotenode> [--targetstorage otherstorage]
[--targetbridge otherbridge]
targetstorage && targetbridge are optional, if not defined it's used same name
than source
targetremotenode is a fqdn host from another cluster.
(source node must be able to root ssh to target node with public key)
source vm is not deleted currently for safety, just stopped and the migrate
lock keeped to avoid
to restart it.
1 private ssh key need to be created for each targetremotenode in:
/etc/pve/priv/migrate_external/id_rsa_mytargetnode
Changelog v3:
- prepare : shell_quote arguments in vm create (to escape options like -cpu
+spectre;+ssbd;)
- phase2 : bugfix for --targetstorage option
Changelog v2:
- add migrate_external api2 (please check the api root permission)
- add targetbridge option
- fix targetremotenode fqdn resolution
- use pvesh to get nextvmid on remote cluster
- add sshkey
- add missing "\n" in some die messages.
Alexandre Derumier (7):
api2 : add migrate_vm_external
migrate : prepare : add create_vm for external migration
migrate : phase1 : skip sync_disk for external migration
migrate : phase2 : migrate external
migrate : phase2_cleanup : migrate_external
migrate : phase3_cleanup : migrate_external
migrate: add sshkey in /etc/pve/priv/migrate_external/
PVE/API2/Qemu.pm | 102 ++++++++++++++++++++++++++++++++-
PVE/CLI/qm.pm | 2 +
PVE/QemuMigrate.pm | 164 ++++++++++++++++++++++++++++++++++++++++++++---------
PVE/QemuServer.pm | 20 +++++--
4 files changed, 253 insertions(+), 35 deletions(-)
_______________________________________________
pve-devel mailing list
pve-devel@pve.proxmox.com
https://pve.proxmox.com/cgi-bin/mailman/listinfo/pve-devel
_______________________________________________
pve-devel mailing list
pve-devel@pve.proxmox.com
https://pve.proxmox.com/cgi-bin/mailman/listinfo/pve-devel
_______________________________________________
pve-devel mailing list
pve-devel@pve.proxmox.com
https://pve.proxmox.com/cgi-bin/mailman/listinfo/pve-devel