From nobody Mon Feb 9 02:13:18 2026 Delivered-To: importer@patchew.org Received-SPF: pass (zoho.com: domain of redhat.com designates 209.132.183.39 as permitted sender) client-ip=209.132.183.39; envelope-from=libvir-list-bounces@redhat.com; helo=mx6-phx2.redhat.com; Authentication-Results: mx.zoho.com; spf=pass (zoho.com: domain of redhat.com designates 209.132.183.39 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com; Return-Path: Received: from mx6-phx2.redhat.com (mx6-phx2.redhat.com [209.132.183.39]) by mx.zohomail.com with SMTPS id 148736058893457.00168691464421; Fri, 17 Feb 2017 11:43:08 -0800 (PST) Received: from lists01.pubmisc.prod.ext.phx2.redhat.com (lists01.pubmisc.prod.ext.phx2.redhat.com [10.5.19.33]) by mx6-phx2.redhat.com (8.14.4/8.14.4) with ESMTP id v1HJe2r7021121; Fri, 17 Feb 2017 14:40:03 -0500 Received: from smtp.corp.redhat.com (int-mx16.intmail.prod.int.phx2.redhat.com [10.5.11.28]) by lists01.pubmisc.prod.ext.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id v1HJdcHg012535 for ; Fri, 17 Feb 2017 14:39:38 -0500 Received: by smtp.corp.redhat.com (Postfix) id 2A627BBA29; Fri, 17 Feb 2017 19:39:38 +0000 (UTC) Received: from localhost.localdomain.com (ovpn-116-126.phx2.redhat.com [10.3.116.126]) by smtp.corp.redhat.com (Postfix) with ESMTP id DF043B95BA for ; Fri, 17 Feb 2017 19:39:37 +0000 (UTC) From: John Ferlan To: libvir-list@redhat.com Date: Fri, 17 Feb 2017 14:39:28 -0500 Message-Id: <20170217193930.14943-12-jferlan@redhat.com> In-Reply-To: <20170217193930.14943-1-jferlan@redhat.com> References: <20170217193930.14943-1-jferlan@redhat.com> X-Scanned-By: MIMEDefang 2.74 on 10.5.11.28 X-loop: libvir-list@redhat.com Subject: [libvirt] [PATCH 11/13] Add new migration flag VIR_MIGRATE_TLS X-BeenThere: libvir-list@redhat.com X-Mailman-Version: 2.1.12 Precedence: junk List-Id: Development discussions about the libvirt library & tools List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Sender: libvir-list-bounces@redhat.com Errors-To: libvir-list-bounces@redhat.com X-ZohoMail: RSF_0 Z_629925259 SPT_0 Content-Type: text/plain; charset="utf-8" Signed-off-by: John Ferlan --- include/libvirt/libvirt-domain.h | 8 ++++++++ src/qemu/qemu_migration.h | 1 + tools/virsh-domain.c | 7 +++++++ 3 files changed, 16 insertions(+) diff --git a/include/libvirt/libvirt-domain.h b/include/libvirt/libvirt-dom= ain.h index e303140..931ff68 100644 --- a/include/libvirt/libvirt-domain.h +++ b/include/libvirt/libvirt-domain.h @@ -815,6 +815,14 @@ typedef enum { * post-copy mode. See virDomainMigrateStartPostCopy for more details. */ VIR_MIGRATE_POSTCOPY =3D (1 << 15), + + /* Setting the VIR_MIGRATE_TLS flag will cause the migration to attempt + * to use the TLS environment configured by the hypervisor in order to + * perform the migration. If incorrectly configured on either source or + * destination, the migration will fail. + */ + VIR_MIGRATE_TLS =3D (1 << 16), + } virDomainMigrateFlags; =20 =20 diff --git a/src/qemu/qemu_migration.h b/src/qemu/qemu_migration.h index 14c6178..8d88632 100644 --- a/src/qemu/qemu_migration.h +++ b/src/qemu/qemu_migration.h @@ -33,6 +33,7 @@ typedef qemuMigrationCompression *qemuMigrationCompressio= nPtr; (VIR_MIGRATE_LIVE | \ VIR_MIGRATE_PEER2PEER | \ VIR_MIGRATE_TUNNELLED | \ + VIR_MIGRATE_TLS | \ VIR_MIGRATE_PERSIST_DEST | \ VIR_MIGRATE_UNDEFINE_SOURCE | \ VIR_MIGRATE_PAUSED | \ diff --git a/tools/virsh-domain.c b/tools/virsh-domain.c index 023ec8a..63ca236 100644 --- a/tools/virsh-domain.c +++ b/tools/virsh-domain.c @@ -10140,6 +10140,10 @@ static const vshCmdOptDef opts_migrate[] =3D { .type =3D VSH_OT_STRING, .help =3D N_("filename containing updated persistent XML for the targ= et") }, + {.name =3D "tls", + .type =3D VSH_OT_BOOL, + .help =3D N_("use TLS for migration") + }, {.name =3D NULL} }; =20 @@ -10381,6 +10385,9 @@ doMigrate(void *opaque) if (vshCommandOptBool(cmd, "postcopy")) flags |=3D VIR_MIGRATE_POSTCOPY; =20 + if (vshCommandOptBool(cmd, "tls")) + flags |=3D VIR_MIGRATE_TLS; + if (flags & VIR_MIGRATE_PEER2PEER || vshCommandOptBool(cmd, "direct"))= { if (virDomainMigrateToURI3(dom, desturi, params, nparams, flags) = =3D=3D 0) ret =3D '0'; --=20 2.9.3 -- libvir-list mailing list libvir-list@redhat.com https://www.redhat.com/mailman/listinfo/libvir-list