From d71d6cdda79e04465d4ad2eac4c0e5a805c9a773 Mon Sep 17 00:00:00 2001 From: Mark O Brien Date: Tue, 15 Feb 2022 17:01:53 +0000 Subject: [PATCH] guest-migrate: add autostart command Signed-off-by: Mark O Brien --- modules/sysadmin_guide/pages/guest_migrate.adoc | 15 ++++++++++++++- 1 file changed, 14 insertions(+), 1 deletion(-) diff --git a/modules/sysadmin_guide/pages/guest_migrate.adoc b/modules/sysadmin_guide/pages/guest_migrate.adoc index 4e4861f..b6070ad 100644 --- a/modules/sysadmin_guide/pages/guest_migrate.adoc +++ b/modules/sysadmin_guide/pages/guest_migrate.adoc @@ -40,10 +40,16 @@ virsh dumpxml guestname > guest.xml depending on if the system was originally xen or such. I normally need to compare an existing xml on the target system and the one we dumped out to make up the differences. -. Define the guest on the new machine: 'virsh define guest.xml'. +. Define the guest on the new machine: + +.... +virsh define guest.xml +.... + Depending on the changes in the xml this may not work and you will need to make many manual changes plus copy the guest.xml to `/etc/libvirtd/qemu` and do a `/sbin/service libvirtd restart` + . Insert iptables rule for nc transfer: + .... @@ -68,6 +74,13 @@ to it. .... ``virsh start guest`` .... + +. To ensure that the new vm starts automatically after boot run: + +.... +virsh autostart guest +.... + . On the source host, rename storage and undefine guest so it's not started. . In ansible change the host_vars to reflect the new host