From nobody Sun May 5 19:34:20 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zoho.com: domain of redhat.com designates 209.132.183.28 as permitted sender) client-ip=209.132.183.28; envelope-from=libvir-list-bounces@redhat.com; helo=mx1.redhat.com; Authentication-Results: mx.zohomail.com; spf=pass (zoho.com: domain of redhat.com designates 209.132.183.28 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com Return-Path: Received: from mx1.redhat.com (mx1.redhat.com [209.132.183.28]) by mx.zohomail.com with SMTPS id 1502189536570599.7816371967232; Tue, 8 Aug 2017 03:52:16 -0700 (PDT) Received: from smtp.corp.redhat.com (int-mx06.intmail.prod.int.phx2.redhat.com [10.5.11.16]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id 245BC61463; Tue, 8 Aug 2017 10:52:14 +0000 (UTC) Received: from colo-mx.corp.redhat.com (colo-mx02.intmail.prod.int.phx2.redhat.com [10.5.11.21]) by smtp.corp.redhat.com (Postfix) with ESMTPS id B8EA84DA27; Tue, 8 Aug 2017 10:52:13 +0000 (UTC) Received: from lists01.pubmisc.prod.ext.phx2.redhat.com (lists01.pubmisc.prod.ext.phx2.redhat.com [10.5.19.33]) by colo-mx.corp.redhat.com (Postfix) with ESMTP id C8B064BB79; Tue, 8 Aug 2017 10:52:11 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx05.intmail.prod.int.phx2.redhat.com [10.5.11.15]) by lists01.pubmisc.prod.ext.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id v78AqASo021633 for ; Tue, 8 Aug 2017 06:52:10 -0400 Received: by smtp.corp.redhat.com (Postfix) id 811EF841D6; Tue, 8 Aug 2017 10:52:10 +0000 (UTC) Received: from mx1.redhat.com (ext-mx03.extmail.prod.ext.phx2.redhat.com [10.5.110.27]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 78E1C841E0 for ; Tue, 8 Aug 2017 10:52:08 +0000 (UTC) Received: from mx0a-001b2d01.pphosted.com (mx0b-001b2d01.pphosted.com [148.163.158.5]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id 6001278EAA for ; Tue, 8 Aug 2017 10:52:06 +0000 (UTC) Received: from pps.filterd (m0098414.ppops.net [127.0.0.1]) by mx0b-001b2d01.pphosted.com (8.16.0.21/8.16.0.21) with SMTP id v787x7TR104814 for ; Tue, 8 Aug 2017 04:03:10 -0400 Received: from e23smtp07.au.ibm.com (e23smtp07.au.ibm.com [202.81.31.140]) by mx0b-001b2d01.pphosted.com with ESMTP id 2c71m718wg-1 (version=TLSv1.2 cipher=AES256-SHA bits=256 verify=NOT) for ; Tue, 08 Aug 2017 04:03:09 -0400 Received: from localhost by e23smtp07.au.ibm.com with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted for from ; Tue, 8 Aug 2017 18:03:06 +1000 Received: from d23relay08.au.ibm.com (202.81.31.227) by e23smtp07.au.ibm.com (202.81.31.204) with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted; Tue, 8 Aug 2017 18:03:05 +1000 Received: from d23av03.au.ibm.com (d23av03.au.ibm.com [9.190.234.97]) by d23relay08.au.ibm.com (8.14.9/8.14.9/NCO v10.0) with ESMTP id v78834Z028180480; Tue, 8 Aug 2017 18:03:04 +1000 Received: from d23av03.au.ibm.com (localhost [127.0.0.1]) by d23av03.au.ibm.com (8.14.4/8.14.4/NCO v10.0 AVout) with ESMTP id v7882t5Y000895; Tue, 8 Aug 2017 18:02:55 +1000 Received: from powerkvmpok002.pok.stglabs.ibm.com (powerkvmpok002.pok.stglabs.ibm.com [9.114.13.10]) by d23av03.au.ibm.com (8.14.4/8.14.4/NCO v10.0 AVin) with ESMTP id v7882nIt000617; Tue, 8 Aug 2017 18:02:54 +1000 DMARC-Filter: OpenDMARC Filter v1.3.2 mx1.redhat.com 245BC61463 Authentication-Results: ext-mx10.extmail.prod.ext.phx2.redhat.com; dmarc=none (p=none dis=none) header.from=linux.vnet.ibm.com Authentication-Results: ext-mx10.extmail.prod.ext.phx2.redhat.com; spf=fail smtp.mailfrom=libvir-list-bounces@redhat.com DKIM-Filter: OpenDKIM Filter v2.11.0 mx1.redhat.com 245BC61463 DMARC-Filter: OpenDMARC Filter v1.3.2 mx1.redhat.com 6001278EAA Authentication-Results: ext-mx03.extmail.prod.ext.phx2.redhat.com; dmarc=none (p=none dis=none) header.from=linux.vnet.ibm.com Authentication-Results: ext-mx03.extmail.prod.ext.phx2.redhat.com; spf=none smtp.mailfrom=kmp@linux.vnet.ibm.com DKIM-Filter: OpenDKIM Filter v2.11.0 mx1.redhat.com 6001278EAA From: Kothapally Madhu Pavan To: libvir-list@redhat.com Date: Tue, 8 Aug 2017 13:32:49 +0530 In-Reply-To: <1502179375-32584-1-git-send-email-kmp@linux.vnet.ibm.com> References: <1502179375-32584-1-git-send-email-kmp@linux.vnet.ibm.com> X-TM-AS-MML: disable x-cbid: 17080808-0044-0000-0000-00000281D97E X-IBM-AV-DETECTION: SAVI=unused REMOTE=unused XFE=unused x-cbparentid: 17080808-0045-0000-0000-000007145A06 Message-Id: <1502179375-32584-2-git-send-email-kmp@linux.vnet.ibm.com> X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10432:, , definitions=2017-08-08_03:, , signatures=0 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 spamscore=0 suspectscore=3 malwarescore=0 phishscore=0 adultscore=0 bulkscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.0.1-1706020000 definitions=main-1708080128 X-Greylist: Delayed for 02:48:58 by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.27]); Tue, 08 Aug 2017 10:52:07 +0000 (UTC) X-Greylist: inspected by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.27]); Tue, 08 Aug 2017 10:52:07 +0000 (UTC) for IP:'148.163.158.5' DOMAIN:'mx0b-001b2d01.pphosted.com' HELO:'mx0a-001b2d01.pphosted.com' FROM:'kmp@linux.vnet.ibm.com' RCPT:'' X-RedHat-Spam-Score: -0.72 (RCVD_IN_DNSWL_LOW, RCVD_IN_MSPIKE_H4, RCVD_IN_MSPIKE_WL) 148.163.158.5 mx0b-001b2d01.pphosted.com 148.163.158.5 mx0b-001b2d01.pphosted.com X-Scanned-By: MIMEDefang 2.78 on 10.5.110.27 X-Scanned-By: MIMEDefang 2.79 on 10.5.11.15 X-loop: libvir-list@redhat.com Cc: Kothapally Madhu Pavan , pkrempa@redhat.com Subject: [libvirt] [PATCH v4 1/7] lib: Add API to dump xml configuration of managed save state domain 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-Scanned-By: MIMEDefang 2.79 on 10.5.11.16 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.39]); Tue, 08 Aug 2017 10:52:15 +0000 (UTC) X-ZohoMail: RSF_0 Z_629925259 SPT_0 Content-Type: text/plain; charset="utf-8" Similar to domainSaveImageGetXMLDesc this commit adds domainManagedSaveGetX= MLDesc API which allows to get the xml of managed save state domain. Signed-off-by: Kothapally Madhu Pavan --- include/libvirt/libvirt-domain.h | 2 ++ src/driver-hypervisor.h | 5 ++++ src/libvirt-domain.c | 49 ++++++++++++++++++++++++++++++++++++= ++++ src/libvirt_public.syms | 5 ++++ src/remote/remote_driver.c | 1 + src/remote/remote_protocol.x | 19 ++++++++++++++-- src/remote_protocol-structs | 8 +++++++ 7 files changed, 87 insertions(+), 2 deletions(-) diff --git a/include/libvirt/libvirt-domain.h b/include/libvirt/libvirt-dom= ain.h index a3bb9cb..8ede912 100644 --- a/include/libvirt/libvirt-domain.h +++ b/include/libvirt/libvirt-domain.h @@ -1209,6 +1209,8 @@ int virDomainHasManagedSaveImage(v= irDomainPtr dom, unsigned int flags); int virDomainManagedSaveRemove(virDomainPtr dom, unsigned int flags); +char * virDomainManagedSaveGetXMLDesc(virDomainPtr domain, + unsigned int flags); =20 /* * Domain core dump diff --git a/src/driver-hypervisor.h b/src/driver-hypervisor.h index 3053d7a..598fc06 100644 --- a/src/driver-hypervisor.h +++ b/src/driver-hypervisor.h @@ -745,6 +745,10 @@ typedef int (*virDrvDomainManagedSaveRemove)(virDomainPtr domain, unsigned int flags); =20 +typedef char * +(*virDrvDomainManagedSaveGetXMLDesc)(virDomainPtr domain, + unsigned int flags); + typedef virDomainSnapshotPtr (*virDrvDomainSnapshotCreateXML)(virDomainPtr domain, const char *xmlDesc, @@ -1422,6 +1426,7 @@ struct _virHypervisorDriver { virDrvDomainManagedSave domainManagedSave; virDrvDomainHasManagedSaveImage domainHasManagedSaveImage; virDrvDomainManagedSaveRemove domainManagedSaveRemove; + virDrvDomainManagedSaveGetXMLDesc domainManagedSaveGetXMLDesc; virDrvDomainSnapshotCreateXML domainSnapshotCreateXML; virDrvDomainSnapshotGetXMLDesc domainSnapshotGetXMLDesc; virDrvDomainSnapshotNum domainSnapshotNum; diff --git a/src/libvirt-domain.c b/src/libvirt-domain.c index 87fca29..cb260e2 100644 --- a/src/libvirt-domain.c +++ b/src/libvirt-domain.c @@ -9298,6 +9298,55 @@ virDomainManagedSaveRemove(virDomainPtr dom, unsigne= d int flags) } =20 =20 +/** + * virDomainManagedSaveGetXMLDesc: + * @domain: a domain object + * @flags: bitwise-OR of subset of virDomainXMLFlags + * + * This method will extract the XML description of the managed save + * state file of a domain. + * + * No security-sensitive data will be included unless @flags contains + * VIR_DOMAIN_XML_SECURE; this flag is rejected on read-only + * connections. For this API, @flags should not contain either + * VIR_DOMAIN_XML_INACTIVE or VIR_DOMAIN_XML_UPDATE_CPU. + * + * Returns a 0 terminated UTF-8 encoded XML instance, or NULL in case of + * error. The caller must free() the returned value. + */ +char * +virDomainManagedSaveGetXMLDesc(virDomainPtr domain, unsigned int flags) +{ + virConnectPtr conn; + + VIR_DOMAIN_DEBUG(domain, "flags=3D%x", flags); + + virResetLastError(); + + virCheckDomainReturn(domain, NULL); + conn =3D domain->conn; + + if ((conn->flags & VIR_CONNECT_RO) && (flags & VIR_DOMAIN_XML_SECURE))= { + virReportError(VIR_ERR_OPERATION_DENIED, "%s", + _("virDomainManagedSaveGetXMLDesc with secure flag"= )); + goto error; + } + + if (conn->driver->domainManagedSaveGetXMLDesc) { + char *ret; + ret =3D conn->driver->domainManagedSaveGetXMLDesc(domain, flags); + if (!ret) + goto error; + return ret; + } + + virReportUnsupportedError(); + + error: + virDispatchError(domain->conn); + return NULL; +} + =20 /** * virDomainOpenConsole: diff --git a/src/libvirt_public.syms b/src/libvirt_public.syms index fac77fb..b38d0bb 100644 --- a/src/libvirt_public.syms +++ b/src/libvirt_public.syms @@ -768,4 +768,9 @@ LIBVIRT_3.4.0 { virStreamSparseSendAll; } LIBVIRT_3.1.0; =20 +LIBVIRT_3.7.0 { + global: + virDomainManagedSaveGetXMLDesc; +} LIBVIRT_3.4.0; + # .... define new API here using predicted next version number .... diff --git a/src/remote/remote_driver.c b/src/remote/remote_driver.c index a57d25f..7a74b87 100644 --- a/src/remote/remote_driver.c +++ b/src/remote/remote_driver.c @@ -8410,6 +8410,7 @@ static virHypervisorDriver hypervisor_driver =3D { .domainManagedSave =3D remoteDomainManagedSave, /* 0.8.0 */ .domainHasManagedSaveImage =3D remoteDomainHasManagedSaveImage, /* 0.8= .0 */ .domainManagedSaveRemove =3D remoteDomainManagedSaveRemove, /* 0.8.0 */ + .domainManagedSaveGetXMLDesc =3D remoteDomainManagedSaveGetXMLDesc, /*= 3.7.0 */ .domainSnapshotCreateXML =3D remoteDomainSnapshotCreateXML, /* 0.8.0 */ .domainSnapshotGetXMLDesc =3D remoteDomainSnapshotGetXMLDesc, /* 0.8.0= */ .domainSnapshotNum =3D remoteDomainSnapshotNum, /* 0.8.0 */ diff --git a/src/remote/remote_protocol.x b/src/remote/remote_protocol.x index 0943208..67d518c 100644 --- a/src/remote/remote_protocol.x +++ b/src/remote/remote_protocol.x @@ -2547,6 +2547,15 @@ struct remote_domain_managed_save_remove_args { unsigned int flags; }; =20 +struct remote_domain_managed_save_get_xml_desc_args { + remote_nonnull_domain dom; + unsigned int flags; +}; + +struct remote_domain_managed_save_get_xml_desc_ret { + remote_nonnull_string xml; +}; + struct remote_domain_snapshot_create_xml_args { remote_nonnull_domain dom; remote_nonnull_string xml_desc; @@ -6064,7 +6073,13 @@ enum remote_procedure { * @generate: both * @acl: domain:write */ - REMOTE_PROC_DOMAIN_SET_BLOCK_THRESHOLD =3D 386 - + REMOTE_PROC_DOMAIN_SET_BLOCK_THRESHOLD =3D 386, =20 + /** + * @generate: both + * @priority: high + * @acl: domain:read + * @acl: domain:read_secure:VIR_DOMAIN_XML_SECURE + */ + REMOTE_PROC_DOMAIN_MANAGED_SAVE_GET_XML_DESC =3D 387 }; diff --git a/src/remote_protocol-structs b/src/remote_protocol-structs index a46fe37..27f95ac 100644 --- a/src/remote_protocol-structs +++ b/src/remote_protocol-structs @@ -1963,6 +1963,13 @@ struct remote_domain_managed_save_remove_args { remote_nonnull_domain dom; u_int flags; }; +struct remote_domain_managed_save_get_xml_desc_args { + remote_nonnull_domain dom; + u_int flags; +}; +struct remote_domain_managed_save_get_xml_desc_ret { + remote_nonnull_string xml; +}; struct remote_domain_snapshot_create_xml_args { remote_nonnull_domain dom; remote_nonnull_string xml_desc; @@ -3233,4 +3240,5 @@ enum remote_procedure { REMOTE_PROC_DOMAIN_SET_VCPU =3D 384, REMOTE_PROC_DOMAIN_EVENT_BLOCK_THRESHOLD =3D 385, REMOTE_PROC_DOMAIN_SET_BLOCK_THRESHOLD =3D 386, + REMOTE_PROC_DOMAIN_MANAGED_SAVE_GET_XML_DESC =3D 387 }; --=20 1.8.3.1 -- libvir-list mailing list libvir-list@redhat.com https://www.redhat.com/mailman/listinfo/libvir-list From nobody Sun May 5 19:34:20 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zoho.com: domain of redhat.com designates 209.132.183.28 as permitted sender) client-ip=209.132.183.28; envelope-from=libvir-list-bounces@redhat.com; helo=mx1.redhat.com; Authentication-Results: mx.zohomail.com; spf=pass (zoho.com: domain of redhat.com designates 209.132.183.28 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com Return-Path: Received: from mx1.redhat.com (mx1.redhat.com [209.132.183.28]) by mx.zohomail.com with SMTPS id 1502182141826498.3001456156087; Tue, 8 Aug 2017 01:49:01 -0700 (PDT) Received: from smtp.corp.redhat.com (int-mx01.intmail.prod.int.phx2.redhat.com [10.5.11.11]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id 5A1D24A702; Tue, 8 Aug 2017 08:48:59 +0000 (UTC) Received: from colo-mx.corp.redhat.com (colo-mx02.intmail.prod.int.phx2.redhat.com [10.5.11.21]) by smtp.corp.redhat.com (Postfix) with ESMTPS id D9626908D4; Tue, 8 Aug 2017 08:48:57 +0000 (UTC) Received: from lists01.pubmisc.prod.ext.phx2.redhat.com (lists01.pubmisc.prod.ext.phx2.redhat.com [10.5.19.33]) by colo-mx.corp.redhat.com (Postfix) with ESMTP id F37C04A467; Tue, 8 Aug 2017 08:48:51 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx02.intmail.prod.int.phx2.redhat.com [10.5.11.12]) by lists01.pubmisc.prod.ext.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id v788moM8029692 for ; Tue, 8 Aug 2017 04:48:50 -0400 Received: by smtp.corp.redhat.com (Postfix) id 0D5C6955C4; Tue, 8 Aug 2017 08:48:50 +0000 (UTC) Received: from mx1.redhat.com (ext-mx01.extmail.prod.ext.phx2.redhat.com [10.5.110.25]) by smtp.corp.redhat.com (Postfix) with ESMTPS id F1AF1955C1 for ; Tue, 8 Aug 2017 08:48:47 +0000 (UTC) Received: from mx0a-001b2d01.pphosted.com (mx0a-001b2d01.pphosted.com [148.163.156.1]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id 3A3D681235 for ; Tue, 8 Aug 2017 08:48:45 +0000 (UTC) Received: from pps.filterd (m0098394.ppops.net [127.0.0.1]) by mx0a-001b2d01.pphosted.com (8.16.0.21/8.16.0.21) with SMTP id v7881wHl002989 for ; Tue, 8 Aug 2017 04:03:14 -0400 Received: from e23smtp08.au.ibm.com (e23smtp08.au.ibm.com [202.81.31.141]) by mx0a-001b2d01.pphosted.com with ESMTP id 2c71knbgj8-1 (version=TLSv1.2 cipher=AES256-SHA bits=256 verify=NOT) for ; Tue, 08 Aug 2017 04:03:14 -0400 Received: from localhost by e23smtp08.au.ibm.com with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted for from ; Tue, 8 Aug 2017 18:03:11 +1000 Received: from d23relay10.au.ibm.com (202.81.31.229) by e23smtp08.au.ibm.com (202.81.31.205) with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted; Tue, 8 Aug 2017 18:03:09 +1000 Received: from d23av03.au.ibm.com (d23av03.au.ibm.com [9.190.234.97]) by d23relay10.au.ibm.com (8.14.9/8.14.9/NCO v10.0) with ESMTP id v78838wi32112668; Tue, 8 Aug 2017 18:03:08 +1000 Received: from d23av03.au.ibm.com (localhost [127.0.0.1]) by d23av03.au.ibm.com (8.14.4/8.14.4/NCO v10.0 AVout) with ESMTP id v7882xj1000946; Tue, 8 Aug 2017 18:02:59 +1000 Received: from powerkvmpok002.pok.stglabs.ibm.com (powerkvmpok002.pok.stglabs.ibm.com [9.114.13.10]) by d23av03.au.ibm.com (8.14.4/8.14.4/NCO v10.0 AVin) with ESMTP id v7882nIu000617; Tue, 8 Aug 2017 18:02:58 +1000 DMARC-Filter: OpenDMARC Filter v1.3.2 mx1.redhat.com 5A1D24A702 Authentication-Results: ext-mx09.extmail.prod.ext.phx2.redhat.com; dmarc=none (p=none dis=none) header.from=linux.vnet.ibm.com Authentication-Results: ext-mx09.extmail.prod.ext.phx2.redhat.com; spf=fail smtp.mailfrom=libvir-list-bounces@redhat.com DKIM-Filter: OpenDKIM Filter v2.11.0 mx1.redhat.com 5A1D24A702 DMARC-Filter: OpenDMARC Filter v1.3.2 mx1.redhat.com 3A3D681235 Authentication-Results: ext-mx01.extmail.prod.ext.phx2.redhat.com; dmarc=none (p=none dis=none) header.from=linux.vnet.ibm.com Authentication-Results: ext-mx01.extmail.prod.ext.phx2.redhat.com; spf=none smtp.mailfrom=kmp@linux.vnet.ibm.com DKIM-Filter: OpenDKIM Filter v2.11.0 mx1.redhat.com 3A3D681235 From: Kothapally Madhu Pavan To: libvir-list@redhat.com Date: Tue, 8 Aug 2017 13:32:50 +0530 In-Reply-To: <1502179375-32584-1-git-send-email-kmp@linux.vnet.ibm.com> References: <1502179375-32584-1-git-send-email-kmp@linux.vnet.ibm.com> X-TM-AS-MML: disable x-cbid: 17080808-0048-0000-0000-00000257DFD8 X-IBM-AV-DETECTION: SAVI=unused REMOTE=unused XFE=unused x-cbparentid: 17080808-0049-0000-0000-0000480B3FB4 Message-Id: <1502179375-32584-3-git-send-email-kmp@linux.vnet.ibm.com> X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10432:, , definitions=2017-08-08_03:, , signatures=0 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 spamscore=0 suspectscore=1 malwarescore=0 phishscore=0 adultscore=0 bulkscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.0.1-1706020000 definitions=main-1708080128 X-Greylist: Delayed for 00:45:37 by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.25]); Tue, 08 Aug 2017 08:48:46 +0000 (UTC) X-Greylist: inspected by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.25]); Tue, 08 Aug 2017 08:48:46 +0000 (UTC) for IP:'148.163.156.1' DOMAIN:'mx0a-001b2d01.pphosted.com' HELO:'mx0a-001b2d01.pphosted.com' FROM:'kmp@linux.vnet.ibm.com' RCPT:'' X-RedHat-Spam-Score: -0.72 (RCVD_IN_DNSWL_LOW, RCVD_IN_MSPIKE_H3, RCVD_IN_MSPIKE_WL) 148.163.156.1 mx0a-001b2d01.pphosted.com 148.163.156.1 mx0a-001b2d01.pphosted.com X-Scanned-By: MIMEDefang 2.78 on 10.5.110.25 X-Scanned-By: MIMEDefang 2.79 on 10.5.11.12 X-loop: libvir-list@redhat.com Cc: Kothapally Madhu Pavan , pkrempa@redhat.com Subject: [libvirt] [PATCH v4 2/7] lib: Add API to edit domain's managed save state xml configuration 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-Scanned-By: MIMEDefang 2.79 on 10.5.11.11 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.38]); Tue, 08 Aug 2017 08:49:00 +0000 (UTC) X-ZohoMail: RSF_0 Z_629925259 SPT_0 Content-Type: text/plain; charset="utf-8" Similar to domainSaveImageDefineXML this commit adds domainManagedSaveDefin= eXML API which allows to edit domain's managed save state xml configuration. Signed-off-by: Kothapally Madhu Pavan --- include/libvirt/libvirt-domain.h | 4 +++ src/driver-hypervisor.h | 6 +++++ src/libvirt-domain.c | 58 ++++++++++++++++++++++++++++++++++++= ++++ src/libvirt_public.syms | 1 + src/remote/remote_driver.c | 1 + src/remote/remote_protocol.x | 16 ++++++++++- src/remote_protocol-structs | 8 +++++- 7 files changed, 92 insertions(+), 2 deletions(-) diff --git a/include/libvirt/libvirt-domain.h b/include/libvirt/libvirt-dom= ain.h index 8ede912..ed2c2b6 100644 --- a/include/libvirt/libvirt-domain.h +++ b/include/libvirt/libvirt-domain.h @@ -1211,6 +1211,10 @@ int virDomainManagedSaveRemove(vi= rDomainPtr dom, unsigned int flags); char * virDomainManagedSaveGetXMLDesc(virDomainPtr domain, unsigned int flags); +int virDomainManagedSaveDefineXML(virDomainPtr domain, + const char *dxml, + unsigned int flags); + =20 /* * Domain core dump diff --git a/src/driver-hypervisor.h b/src/driver-hypervisor.h index 598fc06..0a4181e 100644 --- a/src/driver-hypervisor.h +++ b/src/driver-hypervisor.h @@ -749,6 +749,11 @@ typedef char * (*virDrvDomainManagedSaveGetXMLDesc)(virDomainPtr domain, unsigned int flags); =20 +typedef int +(*virDrvDomainManagedSaveDefineXML)(virDomainPtr domain, + const char *dxml, + unsigned int flags); + typedef virDomainSnapshotPtr (*virDrvDomainSnapshotCreateXML)(virDomainPtr domain, const char *xmlDesc, @@ -1427,6 +1432,7 @@ struct _virHypervisorDriver { virDrvDomainHasManagedSaveImage domainHasManagedSaveImage; virDrvDomainManagedSaveRemove domainManagedSaveRemove; virDrvDomainManagedSaveGetXMLDesc domainManagedSaveGetXMLDesc; + virDrvDomainManagedSaveDefineXML domainManagedSaveDefineXML; virDrvDomainSnapshotCreateXML domainSnapshotCreateXML; virDrvDomainSnapshotGetXMLDesc domainSnapshotGetXMLDesc; virDrvDomainSnapshotNum domainSnapshotNum; diff --git a/src/libvirt-domain.c b/src/libvirt-domain.c index cb260e2..918e81a 100644 --- a/src/libvirt-domain.c +++ b/src/libvirt-domain.c @@ -9349,6 +9349,64 @@ virDomainManagedSaveGetXMLDesc(virDomainPtr domain, = unsigned int flags) =20 =20 /** + * virDomainManagedSaveDefineXML: + * @domain: a domain object + * @dxml: XML config for adjusting guest xml used on restore + * @flags: bitwise-OR of virDomainSaveRestoreFlags + * + * This updates the definition of a domain stored in a saved state + * file. @domain is used to extract the saved state file location. + * + * @dxml can be used to alter host-specific portions of the domain XML + * that will be used on the next start of the domain. For example, it is + * possible to alter the backing filename that is associated with a + * disk device, to match renaming done as part of backing up the disk + * device while the domain is stopped. + * + * Normally, the saved state file will remember whether the domain was + * running or paused, and restore defaults to the same state. + * Specifying VIR_DOMAIN_SAVE_RUNNING or VIR_DOMAIN_SAVE_PAUSED in + * @flags will override the default saved into the file; omitting both + * leaves the file's default unchanged. These two flags are mutually + * exclusive. + * + * Returns 0 in case of success and -1 in case of failure. + */ +int +virDomainManagedSaveDefineXML(virDomainPtr domain, const char *dxml, + unsigned int flags) +{ + virConnectPtr conn; + + VIR_DOMAIN_DEBUG(domain, "flags=3D%x", flags); + + virResetLastError(); + + VIR_EXCLUSIVE_FLAGS_GOTO(VIR_DOMAIN_SAVE_RUNNING, + VIR_DOMAIN_SAVE_PAUSED, + error); + + virCheckDomainReturn(domain, -1); + conn =3D domain->conn; + + if (conn->driver->domainManagedSaveDefineXML) { + int ret; + ret =3D conn->driver->domainManagedSaveDefineXML(domain, dxml, fla= gs); + + if (ret < 0) + goto error; + return ret; + } + + virReportUnsupportedError(); + + error: + virDispatchError(domain->conn); + return -1; +} + + +/** * virDomainOpenConsole: * @dom: a domain object * @dev_name: the console, serial or parallel port device alias, or NULL diff --git a/src/libvirt_public.syms b/src/libvirt_public.syms index b38d0bb..fc4efd9 100644 --- a/src/libvirt_public.syms +++ b/src/libvirt_public.syms @@ -771,6 +771,7 @@ LIBVIRT_3.4.0 { LIBVIRT_3.7.0 { global: virDomainManagedSaveGetXMLDesc; + virDomainManagedSaveDefineXML; } LIBVIRT_3.4.0; =20 # .... define new API here using predicted next version number .... diff --git a/src/remote/remote_driver.c b/src/remote/remote_driver.c index 7a74b87..482d4ce 100644 --- a/src/remote/remote_driver.c +++ b/src/remote/remote_driver.c @@ -8411,6 +8411,7 @@ static virHypervisorDriver hypervisor_driver =3D { .domainHasManagedSaveImage =3D remoteDomainHasManagedSaveImage, /* 0.8= .0 */ .domainManagedSaveRemove =3D remoteDomainManagedSaveRemove, /* 0.8.0 */ .domainManagedSaveGetXMLDesc =3D remoteDomainManagedSaveGetXMLDesc, /*= 3.7.0 */ + .domainManagedSaveDefineXML =3D remoteDomainManagedSaveDefineXML, /* 3= .7.0 */ .domainSnapshotCreateXML =3D remoteDomainSnapshotCreateXML, /* 0.8.0 */ .domainSnapshotGetXMLDesc =3D remoteDomainSnapshotGetXMLDesc, /* 0.8.0= */ .domainSnapshotNum =3D remoteDomainSnapshotNum, /* 0.8.0 */ diff --git a/src/remote/remote_protocol.x b/src/remote/remote_protocol.x index 67d518c..ddc6bda 100644 --- a/src/remote/remote_protocol.x +++ b/src/remote/remote_protocol.x @@ -2556,6 +2556,12 @@ struct remote_domain_managed_save_get_xml_desc_ret { remote_nonnull_string xml; }; =20 +struct remote_domain_managed_save_define_xml_args { + remote_nonnull_domain dom; + remote_string dxml; + unsigned int flags; +}; + struct remote_domain_snapshot_create_xml_args { remote_nonnull_domain dom; remote_nonnull_string xml_desc; @@ -6081,5 +6087,13 @@ enum remote_procedure { * @acl: domain:read * @acl: domain:read_secure:VIR_DOMAIN_XML_SECURE */ - REMOTE_PROC_DOMAIN_MANAGED_SAVE_GET_XML_DESC =3D 387 + REMOTE_PROC_DOMAIN_MANAGED_SAVE_GET_XML_DESC =3D 387, + + /** + * @generate: both + * @priority: high + * @acl: domain:write + * @acl: domain:hibernate + */ + REMOTE_PROC_DOMAIN_MANAGED_SAVE_DEFINE_XML =3D 388 }; diff --git a/src/remote_protocol-structs b/src/remote_protocol-structs index 27f95ac..8075335 100644 --- a/src/remote_protocol-structs +++ b/src/remote_protocol-structs @@ -1970,6 +1970,11 @@ struct remote_domain_managed_save_get_xml_desc_args { struct remote_domain_managed_save_get_xml_desc_ret { remote_nonnull_string xml; }; +struct remote_domain_managed_save_define_xml_args { + remote_nonnull_domain dom; + remote_nonnull_string dxml; + u_int flags; +}; struct remote_domain_snapshot_create_xml_args { remote_nonnull_domain dom; remote_nonnull_string xml_desc; @@ -3240,5 +3245,6 @@ enum remote_procedure { REMOTE_PROC_DOMAIN_SET_VCPU =3D 384, REMOTE_PROC_DOMAIN_EVENT_BLOCK_THRESHOLD =3D 385, REMOTE_PROC_DOMAIN_SET_BLOCK_THRESHOLD =3D 386, - REMOTE_PROC_DOMAIN_MANAGED_SAVE_GET_XML_DESC =3D 387 + REMOTE_PROC_DOMAIN_MANAGED_SAVE_GET_XML_DESC =3D 387, + REMOTE_PROC_DOMAIN_MANAGED_SAVE_DEFINE_XML =3D 388 }; --=20 1.8.3.1 -- libvir-list mailing list libvir-list@redhat.com https://www.redhat.com/mailman/listinfo/libvir-list From nobody Sun May 5 19:34:20 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zoho.com: domain of redhat.com designates 209.132.183.28 as permitted sender) client-ip=209.132.183.28; envelope-from=libvir-list-bounces@redhat.com; helo=mx1.redhat.com; Authentication-Results: mx.zohomail.com; spf=pass (zoho.com: domain of redhat.com designates 209.132.183.28 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com Return-Path: Received: from mx1.redhat.com (mx1.redhat.com [209.132.183.28]) by mx.zohomail.com with SMTPS id 1502194998786750.5615785677841; Tue, 8 Aug 2017 05:23:18 -0700 (PDT) Received: from smtp.corp.redhat.com (int-mx05.intmail.prod.int.phx2.redhat.com [10.5.11.15]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id 291C97EA88; Tue, 8 Aug 2017 12:23:17 +0000 (UTC) Received: from colo-mx.corp.redhat.com (colo-mx01.intmail.prod.int.phx2.redhat.com [10.5.11.20]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 8F51F841EF; Tue, 8 Aug 2017 12:23:16 +0000 (UTC) Received: from lists01.pubmisc.prod.ext.phx2.redhat.com (lists01.pubmisc.prod.ext.phx2.redhat.com [10.5.19.33]) by colo-mx.corp.redhat.com (Postfix) with ESMTP id D101C1808872; Tue, 8 Aug 2017 12:23:14 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx03.intmail.prod.int.phx2.redhat.com [10.5.11.13]) by lists01.pubmisc.prod.ext.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id v78CNDdr029062 for ; Tue, 8 Aug 2017 08:23:14 -0400 Received: by smtp.corp.redhat.com (Postfix) id EF29060A9D; Tue, 8 Aug 2017 12:23:13 +0000 (UTC) Received: from mx1.redhat.com (ext-mx06.extmail.prod.ext.phx2.redhat.com [10.5.110.30]) by smtp.corp.redhat.com (Postfix) with ESMTPS id E624A5C667 for ; Tue, 8 Aug 2017 12:23:11 +0000 (UTC) Received: from mx0a-001b2d01.pphosted.com (mx0a-001b2d01.pphosted.com [148.163.156.1]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id 30206356F2 for ; Tue, 8 Aug 2017 12:23:09 +0000 (UTC) Received: from pps.filterd (m0098409.ppops.net [127.0.0.1]) by mx0a-001b2d01.pphosted.com (8.16.0.21/8.16.0.21) with SMTP id v787xHNJ022497 for ; Tue, 8 Aug 2017 04:03:16 -0400 Received: from e23smtp01.au.ibm.com (e23smtp01.au.ibm.com [202.81.31.143]) by mx0a-001b2d01.pphosted.com with ESMTP id 2c78wj9k52-1 (version=TLSv1.2 cipher=AES256-SHA bits=256 verify=NOT) for ; Tue, 08 Aug 2017 04:03:15 -0400 Received: from localhost by e23smtp01.au.ibm.com with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted for from ; Tue, 8 Aug 2017 18:03:13 +1000 Received: from d23relay09.au.ibm.com (202.81.31.228) by e23smtp01.au.ibm.com (202.81.31.207) with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted; Tue, 8 Aug 2017 18:03:11 +1000 Received: from d23av03.au.ibm.com (d23av03.au.ibm.com [9.190.234.97]) by d23relay09.au.ibm.com (8.14.9/8.14.9/NCO v10.0) with ESMTP id v7883B6h31064142; Tue, 8 Aug 2017 18:03:11 +1000 Received: from d23av03.au.ibm.com (localhost [127.0.0.1]) by d23av03.au.ibm.com (8.14.4/8.14.4/NCO v10.0 AVout) with ESMTP id v78831he001036; Tue, 8 Aug 2017 18:03:02 +1000 Received: from powerkvmpok002.pok.stglabs.ibm.com (powerkvmpok002.pok.stglabs.ibm.com [9.114.13.10]) by d23av03.au.ibm.com (8.14.4/8.14.4/NCO v10.0 AVin) with ESMTP id v7882nIv000617; Tue, 8 Aug 2017 18:03:01 +1000 DMARC-Filter: OpenDMARC Filter v1.3.2 mx1.redhat.com 291C97EA88 Authentication-Results: ext-mx04.extmail.prod.ext.phx2.redhat.com; dmarc=none (p=none dis=none) header.from=linux.vnet.ibm.com Authentication-Results: ext-mx04.extmail.prod.ext.phx2.redhat.com; spf=fail smtp.mailfrom=libvir-list-bounces@redhat.com DKIM-Filter: OpenDKIM Filter v2.11.0 mx1.redhat.com 291C97EA88 DMARC-Filter: OpenDMARC Filter v1.3.2 mx1.redhat.com 30206356F2 Authentication-Results: ext-mx06.extmail.prod.ext.phx2.redhat.com; dmarc=none (p=none dis=none) header.from=linux.vnet.ibm.com Authentication-Results: ext-mx06.extmail.prod.ext.phx2.redhat.com; spf=none smtp.mailfrom=kmp@linux.vnet.ibm.com DKIM-Filter: OpenDKIM Filter v2.11.0 mx1.redhat.com 30206356F2 From: Kothapally Madhu Pavan To: libvir-list@redhat.com Date: Tue, 8 Aug 2017 13:32:51 +0530 In-Reply-To: <1502179375-32584-1-git-send-email-kmp@linux.vnet.ibm.com> References: <1502179375-32584-1-git-send-email-kmp@linux.vnet.ibm.com> X-TM-AS-MML: disable x-cbid: 17080808-1617-0000-0000-000001FA3BA7 X-IBM-AV-DETECTION: SAVI=unused REMOTE=unused XFE=unused x-cbparentid: 17080808-1618-0000-0000-00004844FBEB Message-Id: <1502179375-32584-4-git-send-email-kmp@linux.vnet.ibm.com> X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10432:, , definitions=2017-08-08_03:, , signatures=0 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 spamscore=0 suspectscore=3 malwarescore=0 phishscore=0 adultscore=0 bulkscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.0.1-1706020000 definitions=main-1708080128 X-Greylist: Delayed for 04:20:01 by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.30]); Tue, 08 Aug 2017 12:23:10 +0000 (UTC) X-Greylist: inspected by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.30]); Tue, 08 Aug 2017 12:23:10 +0000 (UTC) for IP:'148.163.156.1' DOMAIN:'mx0a-001b2d01.pphosted.com' HELO:'mx0a-001b2d01.pphosted.com' FROM:'kmp@linux.vnet.ibm.com' RCPT:'' X-RedHat-Spam-Score: -0.72 (RCVD_IN_DNSWL_LOW, RCVD_IN_MSPIKE_H3, RCVD_IN_MSPIKE_WL) 148.163.156.1 mx0a-001b2d01.pphosted.com 148.163.156.1 mx0a-001b2d01.pphosted.com X-Scanned-By: MIMEDefang 2.78 on 10.5.110.30 X-Scanned-By: MIMEDefang 2.79 on 10.5.11.13 X-loop: libvir-list@redhat.com Cc: Kothapally Madhu Pavan , pkrempa@redhat.com Subject: [libvirt] [PATCH v4 3/7] qemu: Implement qemuDomainManagedSaveGetXMLDesc 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-Scanned-By: MIMEDefang 2.79 on 10.5.11.15 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.28]); Tue, 08 Aug 2017 12:23:17 +0000 (UTC) X-ZohoMail: RSF_0 Z_629925259 SPT_0 Content-Type: text/plain; charset="utf-8" This commit adds qemu driver implementation to get xml description for managed save state domain. Signed-off-by: Kothapally Madhu Pavan --- src/qemu/qemu_driver.c | 46 ++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 46 insertions(+) diff --git a/src/qemu/qemu_driver.c b/src/qemu/qemu_driver.c index b3f65f4..ec73dc1 100644 --- a/src/qemu/qemu_driver.c +++ b/src/qemu/qemu_driver.c @@ -6797,6 +6797,51 @@ qemuDomainSaveImageDefineXML(virConnectPtr conn, con= st char *path, return ret; } =20 +static char * +qemuDomainManagedSaveGetXMLDesc(virDomainPtr dom, unsigned int flags) +{ + virQEMUDriverPtr driver =3D dom->conn->privateData; + virDomainObjPtr vm; + char *path =3D NULL; + char *ret =3D NULL; + virDomainDefPtr def =3D NULL; + int fd =3D -1; + virQEMUSaveDataPtr data =3D NULL; + + /* We only take subset of virDomainDefFormat flags. */ + virCheckFlags(VIR_DOMAIN_XML_SECURE, NULL); + + if (!(vm =3D qemuDomObjFromDomain(dom))) + return ret; + + path =3D qemuDomainManagedSavePath(driver, vm); + + if (!path) + goto cleanup; + + if (!virFileExists(path)) { + virReportError(VIR_ERR_OPERATION_INVALID, + "%s",_("domain does not have managed save image")); + goto cleanup; + } + + fd =3D qemuDomainSaveImageOpen(driver, path, &def, &data, + false, NULL, false, false); + if (fd < 0) + goto cleanup; + if (virDomainManagedSaveGetXMLDescEnsureACL(dom->conn, def, flags) < 0) + goto cleanup; + ret =3D qemuDomainDefFormatXML(driver, def, flags); + + cleanup: + virQEMUSaveDataFree(data); + virDomainDefFree(def); + VIR_FORCE_CLOSE(fd); + virDomainObjEndAPI(&vm); + VIR_FREE(path); + return ret; +} + /* Return 0 on success, 1 if incomplete saved image was silently unlinked, * and -1 on failure with error raised. */ static int @@ -20839,6 +20884,7 @@ static virHypervisorDriver qemuHypervisorDriver =3D= { .domainManagedSave =3D qemuDomainManagedSave, /* 0.8.0 */ .domainHasManagedSaveImage =3D qemuDomainHasManagedSaveImage, /* 0.8.0= */ .domainManagedSaveRemove =3D qemuDomainManagedSaveRemove, /* 0.8.0 */ + .domainManagedSaveGetXMLDesc =3D qemuDomainManagedSaveGetXMLDesc, /* 3= .7.0 */ .domainSnapshotCreateXML =3D qemuDomainSnapshotCreateXML, /* 0.8.0 */ .domainSnapshotGetXMLDesc =3D qemuDomainSnapshotGetXMLDesc, /* 0.8.0 */ .domainSnapshotNum =3D qemuDomainSnapshotNum, /* 0.8.0 */ --=20 1.8.3.1 -- libvir-list mailing list libvir-list@redhat.com https://www.redhat.com/mailman/listinfo/libvir-list From nobody Sun May 5 19:34:20 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zoho.com: domain of redhat.com designates 209.132.183.28 as permitted sender) client-ip=209.132.183.28; envelope-from=libvir-list-bounces@redhat.com; helo=mx1.redhat.com; Authentication-Results: mx.zohomail.com; spf=pass (zoho.com: domain of redhat.com designates 209.132.183.28 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com Return-Path: Received: from mx1.redhat.com (mx1.redhat.com [209.132.183.28]) by mx.zohomail.com with SMTPS id 1502186941883291.41670183154054; Tue, 8 Aug 2017 03:09:01 -0700 (PDT) Received: from smtp.corp.redhat.com (int-mx02.intmail.prod.int.phx2.redhat.com [10.5.11.12]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id 47754769EE; Tue, 8 Aug 2017 10:08:59 +0000 (UTC) Received: from colo-mx.corp.redhat.com (colo-mx01.intmail.prod.int.phx2.redhat.com [10.5.11.20]) by smtp.corp.redhat.com (Postfix) with ESMTPS id C94AD7FCF9; Tue, 8 Aug 2017 10:08:58 +0000 (UTC) Received: from lists01.pubmisc.prod.ext.phx2.redhat.com (lists01.pubmisc.prod.ext.phx2.redhat.com [10.5.19.33]) by colo-mx.corp.redhat.com (Postfix) with ESMTP id D41041803B22; Tue, 8 Aug 2017 10:08:57 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx03.intmail.prod.int.phx2.redhat.com [10.5.11.13]) by lists01.pubmisc.prod.ext.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id v78A8tqU000655 for ; Tue, 8 Aug 2017 06:08:55 -0400 Received: by smtp.corp.redhat.com (Postfix) id D9BC160BE2; Tue, 8 Aug 2017 10:08:55 +0000 (UTC) Received: from mx1.redhat.com (ext-mx08.extmail.prod.ext.phx2.redhat.com [10.5.110.32]) by smtp.corp.redhat.com (Postfix) with ESMTPS id D15DD60A9D for ; Tue, 8 Aug 2017 10:08:53 +0000 (UTC) Received: from mx0a-001b2d01.pphosted.com (mx0a-001b2d01.pphosted.com [148.163.156.1]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id ADCC9C057FAD for ; Tue, 8 Aug 2017 10:08:51 +0000 (UTC) Received: from pps.filterd (m0098404.ppops.net [127.0.0.1]) by mx0a-001b2d01.pphosted.com (8.16.0.21/8.16.0.21) with SMTP id v787wsxq002144 for ; Tue, 8 Aug 2017 04:03:18 -0400 Received: from e23smtp04.au.ibm.com (e23smtp04.au.ibm.com [202.81.31.146]) by mx0a-001b2d01.pphosted.com with ESMTP id 2c78u0spr6-1 (version=TLSv1.2 cipher=AES256-SHA bits=256 verify=NOT) for ; Tue, 08 Aug 2017 04:03:17 -0400 Received: from localhost by e23smtp04.au.ibm.com with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted for from ; Tue, 8 Aug 2017 18:03:15 +1000 Received: from d23relay09.au.ibm.com (202.81.31.228) by e23smtp04.au.ibm.com (202.81.31.210) with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted; Tue, 8 Aug 2017 18:03:13 +1000 Received: from d23av03.au.ibm.com (d23av03.au.ibm.com [9.190.234.97]) by d23relay09.au.ibm.com (8.14.9/8.14.9/NCO v10.0) with ESMTP id v7883DE633292532; Tue, 8 Aug 2017 18:03:13 +1000 Received: from d23av03.au.ibm.com (localhost [127.0.0.1]) by d23av03.au.ibm.com (8.14.4/8.14.4/NCO v10.0 AVout) with ESMTP id v78834l1001096; Tue, 8 Aug 2017 18:03:04 +1000 Received: from powerkvmpok002.pok.stglabs.ibm.com (powerkvmpok002.pok.stglabs.ibm.com [9.114.13.10]) by d23av03.au.ibm.com (8.14.4/8.14.4/NCO v10.0 AVin) with ESMTP id v7882nIw000617; Tue, 8 Aug 2017 18:03:03 +1000 DMARC-Filter: OpenDMARC Filter v1.3.2 mx1.redhat.com 47754769EE Authentication-Results: ext-mx03.extmail.prod.ext.phx2.redhat.com; dmarc=none (p=none dis=none) header.from=linux.vnet.ibm.com Authentication-Results: ext-mx03.extmail.prod.ext.phx2.redhat.com; spf=fail smtp.mailfrom=libvir-list-bounces@redhat.com DKIM-Filter: OpenDKIM Filter v2.11.0 mx1.redhat.com 47754769EE DMARC-Filter: OpenDMARC Filter v1.3.2 mx1.redhat.com ADCC9C057FAD Authentication-Results: ext-mx08.extmail.prod.ext.phx2.redhat.com; dmarc=none (p=none dis=none) header.from=linux.vnet.ibm.com Authentication-Results: ext-mx08.extmail.prod.ext.phx2.redhat.com; spf=none smtp.mailfrom=kmp@linux.vnet.ibm.com DKIM-Filter: OpenDKIM Filter v2.11.0 mx1.redhat.com ADCC9C057FAD From: Kothapally Madhu Pavan To: libvir-list@redhat.com Date: Tue, 8 Aug 2017 13:32:52 +0530 In-Reply-To: <1502179375-32584-1-git-send-email-kmp@linux.vnet.ibm.com> References: <1502179375-32584-1-git-send-email-kmp@linux.vnet.ibm.com> X-TM-AS-MML: disable x-cbid: 17080808-0012-0000-0000-00000258BE38 X-IBM-AV-DETECTION: SAVI=unused REMOTE=unused XFE=unused x-cbparentid: 17080808-0013-0000-0000-00000773C7A2 Message-Id: <1502179375-32584-5-git-send-email-kmp@linux.vnet.ibm.com> X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10432:, , definitions=2017-08-08_03:, , signatures=0 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 spamscore=0 suspectscore=3 malwarescore=0 phishscore=0 adultscore=0 bulkscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.0.1-1706020000 definitions=main-1708080128 X-Greylist: Delayed for 02:05:43 by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.32]); Tue, 08 Aug 2017 10:08:52 +0000 (UTC) X-Greylist: inspected by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.32]); Tue, 08 Aug 2017 10:08:52 +0000 (UTC) for IP:'148.163.156.1' DOMAIN:'mx0a-001b2d01.pphosted.com' HELO:'mx0a-001b2d01.pphosted.com' FROM:'kmp@linux.vnet.ibm.com' RCPT:'' X-RedHat-Spam-Score: -0.72 (RCVD_IN_DNSWL_LOW, RCVD_IN_MSPIKE_H3, RCVD_IN_MSPIKE_WL) 148.163.156.1 mx0a-001b2d01.pphosted.com 148.163.156.1 mx0a-001b2d01.pphosted.com X-Scanned-By: MIMEDefang 2.78 on 10.5.110.32 X-Scanned-By: MIMEDefang 2.79 on 10.5.11.13 X-loop: libvir-list@redhat.com Cc: Kothapally Madhu Pavan , pkrempa@redhat.com Subject: [libvirt] [PATCH v4 4/7] qemu: Implement qemuDomainManagedSaveDefineXML 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-Scanned-By: MIMEDefang 2.79 on 10.5.11.12 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.27]); Tue, 08 Aug 2017 10:09:00 +0000 (UTC) X-ZohoMail: RSF_0 Z_629925259 SPT_0 Content-Type: text/plain; charset="utf-8" This commit adds qemu driver implementation to edit xml configuration of managed save state file of a domain. Signed-off-by: Kothapally Madhu Pavan --- src/qemu/qemu_driver.c | 41 +++++++++++++++++++++++++++++++++++++++++ 1 file changed, 41 insertions(+) diff --git a/src/qemu/qemu_driver.c b/src/qemu/qemu_driver.c index ec73dc1..b6db435 100644 --- a/src/qemu/qemu_driver.c +++ b/src/qemu/qemu_driver.c @@ -6842,6 +6842,46 @@ qemuDomainManagedSaveGetXMLDesc(virDomainPtr dom, un= signed int flags) return ret; } =20 +static int +qemuDomainManagedSaveDefineXML(virDomainPtr dom, const char *dxml, + unsigned int flags) +{ + virQEMUDriverPtr driver =3D dom->conn->privateData; + virConnectPtr conn =3D dom->conn; + virDomainObjPtr vm; + char *path =3D NULL; + int ret; + + if (!(vm =3D qemuDomObjFromDomain(dom))) + return -1; + + path =3D qemuDomainManagedSavePath(driver, vm); + virDomainObjEndAPI(&vm); + + if (!path) + goto error; + + if (!virFileExists(path)) { + virReportError(VIR_ERR_OPERATION_INVALID, + "%s",_("domain does not have managed save image")); + goto error; + } + + ret =3D qemuDomainSaveImageDefineXML(conn, path, dxml, flags); + + VIR_FREE(path); + + if (ret < 0) + goto error; + + return ret; + + error: + VIR_FREE(path); + virDispatchError(conn); + return -1; +} + /* Return 0 on success, 1 if incomplete saved image was silently unlinked, * and -1 on failure with error raised. */ static int @@ -20885,6 +20925,7 @@ static virHypervisorDriver qemuHypervisorDriver =3D= { .domainHasManagedSaveImage =3D qemuDomainHasManagedSaveImage, /* 0.8.0= */ .domainManagedSaveRemove =3D qemuDomainManagedSaveRemove, /* 0.8.0 */ .domainManagedSaveGetXMLDesc =3D qemuDomainManagedSaveGetXMLDesc, /* 3= .7.0 */ + .domainManagedSaveDefineXML =3D qemuDomainManagedSaveDefineXML, /* 3.7= .0 */ .domainSnapshotCreateXML =3D qemuDomainSnapshotCreateXML, /* 0.8.0 */ .domainSnapshotGetXMLDesc =3D qemuDomainSnapshotGetXMLDesc, /* 0.8.0 */ .domainSnapshotNum =3D qemuDomainSnapshotNum, /* 0.8.0 */ --=20 1.8.3.1 -- libvir-list mailing list libvir-list@redhat.com https://www.redhat.com/mailman/listinfo/libvir-list From nobody Sun May 5 19:34:20 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zoho.com: domain of redhat.com designates 209.132.183.28 as permitted sender) client-ip=209.132.183.28; envelope-from=libvir-list-bounces@redhat.com; helo=mx1.redhat.com; Authentication-Results: mx.zohomail.com; spf=pass (zoho.com: domain of redhat.com designates 209.132.183.28 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com Return-Path: Received: from mx1.redhat.com (mx1.redhat.com [209.132.183.28]) by mx.zohomail.com with SMTPS id 1502195963539164.14810794345033; Tue, 8 Aug 2017 05:39:23 -0700 (PDT) Received: from smtp.corp.redhat.com (int-mx02.intmail.prod.int.phx2.redhat.com [10.5.11.12]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id 06785C0587DD; Tue, 8 Aug 2017 12:39:21 +0000 (UTC) Received: from colo-mx.corp.redhat.com (colo-mx01.intmail.prod.int.phx2.redhat.com [10.5.11.20]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 3E8D695882; Tue, 8 Aug 2017 12:39:20 +0000 (UTC) Received: from lists01.pubmisc.prod.ext.phx2.redhat.com (lists01.pubmisc.prod.ext.phx2.redhat.com [10.5.19.33]) by colo-mx.corp.redhat.com (Postfix) with ESMTP id 1B9481803B22; Tue, 8 Aug 2017 12:39:19 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx01.intmail.prod.int.phx2.redhat.com [10.5.11.11]) by lists01.pubmisc.prod.ext.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id v78CdHX3003277 for ; Tue, 8 Aug 2017 08:39:17 -0400 Received: by smtp.corp.redhat.com (Postfix) id C5462908F9; Tue, 8 Aug 2017 12:39:17 +0000 (UTC) Received: from mx1.redhat.com (ext-mx03.extmail.prod.ext.phx2.redhat.com [10.5.110.27]) by smtp.corp.redhat.com (Postfix) with ESMTPS id BF2B0908F8 for ; Tue, 8 Aug 2017 12:39:14 +0000 (UTC) Received: from mx0a-001b2d01.pphosted.com (mx0a-001b2d01.pphosted.com [148.163.156.1]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id D90017C838 for ; Tue, 8 Aug 2017 12:39:12 +0000 (UTC) Received: from pps.filterd (m0098409.ppops.net [127.0.0.1]) by mx0a-001b2d01.pphosted.com (8.16.0.21/8.16.0.21) with SMTP id v787xE7J022280 for ; Tue, 8 Aug 2017 04:03:22 -0400 Received: from e23smtp02.au.ibm.com (e23smtp02.au.ibm.com [202.81.31.144]) by mx0a-001b2d01.pphosted.com with ESMTP id 2c78wj9k9w-1 (version=TLSv1.2 cipher=AES256-SHA bits=256 verify=NOT) for ; Tue, 08 Aug 2017 04:03:22 -0400 Received: from localhost by e23smtp02.au.ibm.com with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted for from ; Tue, 8 Aug 2017 18:03:20 +1000 Received: from d23relay09.au.ibm.com (202.81.31.228) by e23smtp02.au.ibm.com (202.81.31.208) with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted; Tue, 8 Aug 2017 18:03:17 +1000 Received: from d23av03.au.ibm.com (d23av03.au.ibm.com [9.190.234.97]) by d23relay09.au.ibm.com (8.14.9/8.14.9/NCO v10.0) with ESMTP id v7883GDJ30474446; Tue, 8 Aug 2017 18:03:16 +1000 Received: from d23av03.au.ibm.com (localhost [127.0.0.1]) by d23av03.au.ibm.com (8.14.4/8.14.4/NCO v10.0 AVout) with ESMTP id v78837ZC001163; Tue, 8 Aug 2017 18:03:07 +1000 Received: from powerkvmpok002.pok.stglabs.ibm.com (powerkvmpok002.pok.stglabs.ibm.com [9.114.13.10]) by d23av03.au.ibm.com (8.14.4/8.14.4/NCO v10.0 AVin) with ESMTP id v7882nIx000617; Tue, 8 Aug 2017 18:03:06 +1000 DMARC-Filter: OpenDMARC Filter v1.3.2 mx1.redhat.com 06785C0587DD Authentication-Results: ext-mx08.extmail.prod.ext.phx2.redhat.com; dmarc=none (p=none dis=none) header.from=linux.vnet.ibm.com Authentication-Results: ext-mx08.extmail.prod.ext.phx2.redhat.com; spf=fail smtp.mailfrom=libvir-list-bounces@redhat.com DKIM-Filter: OpenDKIM Filter v2.11.0 mx1.redhat.com 06785C0587DD DMARC-Filter: OpenDMARC Filter v1.3.2 mx1.redhat.com D90017C838 Authentication-Results: ext-mx03.extmail.prod.ext.phx2.redhat.com; dmarc=none (p=none dis=none) header.from=linux.vnet.ibm.com Authentication-Results: ext-mx03.extmail.prod.ext.phx2.redhat.com; spf=none smtp.mailfrom=kmp@linux.vnet.ibm.com DKIM-Filter: OpenDKIM Filter v2.11.0 mx1.redhat.com D90017C838 From: Kothapally Madhu Pavan To: libvir-list@redhat.com Date: Tue, 8 Aug 2017 13:32:53 +0530 In-Reply-To: <1502179375-32584-1-git-send-email-kmp@linux.vnet.ibm.com> References: <1502179375-32584-1-git-send-email-kmp@linux.vnet.ibm.com> X-TM-AS-MML: disable x-cbid: 17080808-0004-0000-0000-00000229B9FF X-IBM-AV-DETECTION: SAVI=unused REMOTE=unused XFE=unused x-cbparentid: 17080808-0005-0000-0000-00005E0FE504 Message-Id: <1502179375-32584-6-git-send-email-kmp@linux.vnet.ibm.com> X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10432:, , definitions=2017-08-08_03:, , signatures=0 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 spamscore=0 suspectscore=3 malwarescore=0 phishscore=0 adultscore=0 bulkscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.0.1-1706020000 definitions=main-1708080128 X-Greylist: IP, sender and recipient auto-whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.27]); Tue, 08 Aug 2017 12:39:14 +0000 (UTC) X-Greylist: inspected by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.27]); Tue, 08 Aug 2017 12:39:14 +0000 (UTC) for IP:'148.163.156.1' DOMAIN:'mx0a-001b2d01.pphosted.com' HELO:'mx0a-001b2d01.pphosted.com' FROM:'kmp@linux.vnet.ibm.com' RCPT:'' X-RedHat-Spam-Score: -0.72 (RCVD_IN_DNSWL_LOW, RCVD_IN_MSPIKE_H3, RCVD_IN_MSPIKE_WL) 148.163.156.1 mx0a-001b2d01.pphosted.com 148.163.156.1 mx0a-001b2d01.pphosted.com X-Scanned-By: MIMEDefang 2.78 on 10.5.110.27 X-Scanned-By: MIMEDefang 2.79 on 10.5.11.11 X-loop: libvir-list@redhat.com Cc: Kothapally Madhu Pavan , pkrempa@redhat.com Subject: [libvirt] [PATCH v4 5/7] virsh: Implement managedsave-define command 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-Scanned-By: MIMEDefang 2.79 on 10.5.11.12 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.32]); Tue, 08 Aug 2017 12:39:22 +0000 (UTC) X-ZohoMail: RSF_0 Z_629925259 SPT_0 Content-Type: text/plain; charset="utf-8" Add a simple virsh command handler which makes use of the new API. Signed-off-by: Kothapally Madhu Pavan --- tools/virsh-domain.c | 79 ++++++++++++++++++++++++++++++++++++++++++++++++= ++++ tools/virsh.pod | 14 ++++++++++ 2 files changed, 93 insertions(+) diff --git a/tools/virsh-domain.c b/tools/virsh-domain.c index 512804c..8baea2a 100644 --- a/tools/virsh-domain.c +++ b/tools/virsh-domain.c @@ -4705,6 +4705,79 @@ cmdManagedSaveRemove(vshControl *ctl, const vshCmd *= cmd) } =20 /* + * "managedsave-define" command + */ +static const vshCmdInfo info_managed_save_define[] =3D { + {.name =3D "help", + .data =3D N_("redefine the XML for a domain's managed save state file= ") + }, + {.name =3D "desc", + .data =3D N_("Replace the domain XML associated with a managed save s= tate file") + }, + {.name =3D NULL} +}; + +static const vshCmdOptDef opts_managed_save_define[] =3D { + VIRSH_COMMON_OPT_DOMAIN_FULL, + {.name =3D "xml", + .type =3D VSH_OT_DATA, + .flags =3D VSH_OFLAG_REQ, + .help =3D N_("filename containing updated XML for the target") + }, + {.name =3D "running", + .type =3D VSH_OT_BOOL, + .help =3D N_("set domain to be running on start") + }, + {.name =3D "paused", + .type =3D VSH_OT_BOOL, + .help =3D N_("set domain to be paused on start") + }, + {.name =3D NULL} +}; + +static bool +cmdManagedSaveDefine(vshControl *ctl, const vshCmd *cmd) +{ + bool ret =3D false; + virDomainPtr dom =3D NULL; + const char *xmlfile =3D NULL; + char *xml =3D NULL; + unsigned int flags =3D 0; + + if (vshCommandOptBool(cmd, "running")) + flags |=3D VIR_DOMAIN_SAVE_RUNNING; + if (vshCommandOptBool(cmd, "paused")) + flags |=3D VIR_DOMAIN_SAVE_PAUSED; + + VSH_EXCLUSIVE_OPTIONS("running", "paused"); + + if (vshCommandOptStringReq(ctl, cmd, "xml", &xmlfile) < 0) + return false; + + if (virFileReadAll(xmlfile, VSH_MAX_XML_FILE, &xml) < 0) + return false; + + dom =3D virshCommandOptDomain(ctl, cmd, NULL); + if (dom =3D=3D NULL) + goto cleanup; + + if (virDomainManagedSaveDefineXML(dom, xml, flags) < 0) { + vshError(ctl, _("Failed to update %s XML configuration"), + virDomainGetName(dom)); + goto cleanup; + } + + vshPrintExtra(ctl, _("Managed save state file of domain %s updated.\n"= ), + virDomainGetName(dom)); + ret =3D true; + + cleanup: + virshDomainFree(dom); + VIR_FREE(xml); + return ret; +} + +/* * "schedinfo" command */ static const vshCmdInfo info_schedinfo[] =3D { @@ -13845,6 +13918,12 @@ const vshCmdDef domManagementCmds[] =3D { .info =3D info_managedsaveremove, .flags =3D 0 }, + {.name =3D "managedsave-define", + .handler =3D cmdManagedSaveDefine, + .opts =3D opts_managed_save_define, + .info =3D info_managed_save_define, + .flags =3D 0 + }, {.name =3D "memtune", .handler =3D cmdMemtune, .opts =3D opts_memtune, diff --git a/tools/virsh.pod b/tools/virsh.pod index 43d6f0c..11e2321 100644 --- a/tools/virsh.pod +++ b/tools/virsh.pod @@ -1630,6 +1630,20 @@ has any managed save image. Remove the B state file for a domain, if it exists. This ensures the domain will do a full boot the next time it is started. =20 +=3Ditem B I I [{I<--running> | I<--paused= >}] + +Update the domain XML that will be used when I is later +started. The I argument must be a file name containing +the alternative XML, with changes only in the host-specific portions of +the domain XML. For example, it can be used to account for file naming +differences resulting from creating disk snapshots of underlying storage +after the guest was saved. + +The managed save image records whether the domain should be started to a +running or paused state. Normally, this command does not alter the +recorded state; passing either the I<--running> or I<--paused> flag +will allow overriding which state the B should use. + =3Ditem B [I] =20 Provide the maximum number of virtual CPUs supported for a guest VM on --=20 1.8.3.1 -- libvir-list mailing list libvir-list@redhat.com https://www.redhat.com/mailman/listinfo/libvir-list From nobody Sun May 5 19:34:20 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zoho.com: domain of redhat.com designates 209.132.183.28 as permitted sender) client-ip=209.132.183.28; envelope-from=libvir-list-bounces@redhat.com; helo=mx1.redhat.com; Authentication-Results: mx.zohomail.com; spf=pass (zoho.com: domain of redhat.com designates 209.132.183.28 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com Return-Path: Received: from mx1.redhat.com (mx1.redhat.com [209.132.183.28]) by mx.zohomail.com with SMTPS id 1502188879458457.9482785576779; Tue, 8 Aug 2017 03:41:19 -0700 (PDT) Received: from smtp.corp.redhat.com (int-mx04.intmail.prod.int.phx2.redhat.com [10.5.11.14]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id C5E0B883B9; Tue, 8 Aug 2017 10:41:16 +0000 (UTC) Received: from colo-mx.corp.redhat.com (colo-mx01.intmail.prod.int.phx2.redhat.com [10.5.11.20]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 3D5A59154C; Tue, 8 Aug 2017 10:41:16 +0000 (UTC) Received: from lists01.pubmisc.prod.ext.phx2.redhat.com (lists01.pubmisc.prod.ext.phx2.redhat.com [10.5.19.33]) by colo-mx.corp.redhat.com (Postfix) with ESMTP id E0D571805974; Tue, 8 Aug 2017 10:41:14 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx01.intmail.prod.int.phx2.redhat.com [10.5.11.11]) by lists01.pubmisc.prod.ext.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id v78AfDPX016159 for ; Tue, 8 Aug 2017 06:41:13 -0400 Received: by smtp.corp.redhat.com (Postfix) id 9F0335C7C4; Tue, 8 Aug 2017 10:41:13 +0000 (UTC) Received: from mx1.redhat.com (ext-mx08.extmail.prod.ext.phx2.redhat.com [10.5.110.32]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 97606908D1 for ; Tue, 8 Aug 2017 10:41:11 +0000 (UTC) Received: from mx0a-001b2d01.pphosted.com (mx0b-001b2d01.pphosted.com [148.163.158.5]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id F0F79C0587D3 for ; Tue, 8 Aug 2017 10:41:08 +0000 (UTC) Received: from pps.filterd (m0098421.ppops.net [127.0.0.1]) by mx0a-001b2d01.pphosted.com (8.16.0.21/8.16.0.21) with SMTP id v7884cDC128423 for ; Tue, 8 Aug 2017 04:04:44 -0400 Received: from e23smtp06.au.ibm.com (e23smtp06.au.ibm.com [202.81.31.148]) by mx0a-001b2d01.pphosted.com with ESMTP id 2c799ygfyg-1 (version=TLSv1.2 cipher=AES256-SHA bits=256 verify=NOT) for ; Tue, 08 Aug 2017 04:04:43 -0400 Received: from localhost by e23smtp06.au.ibm.com with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted for from ; Tue, 8 Aug 2017 18:04:36 +1000 Received: from d23relay10.au.ibm.com (202.81.31.229) by e23smtp06.au.ibm.com (202.81.31.212) with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted; Tue, 8 Aug 2017 18:04:33 +1000 Received: from d23av03.au.ibm.com (d23av03.au.ibm.com [9.190.234.97]) by d23relay10.au.ibm.com (8.14.9/8.14.9/NCO v10.0) with ESMTP id v7883IDp11731008; Tue, 8 Aug 2017 18:03:18 +1000 Received: from d23av03.au.ibm.com (localhost [127.0.0.1]) by d23av03.au.ibm.com (8.14.4/8.14.4/NCO v10.0 AVout) with ESMTP id v78839rF001244; Tue, 8 Aug 2017 18:03:09 +1000 Received: from powerkvmpok002.pok.stglabs.ibm.com (powerkvmpok002.pok.stglabs.ibm.com [9.114.13.10]) by d23av03.au.ibm.com (8.14.4/8.14.4/NCO v10.0 AVin) with ESMTP id v7882nJ0000617; Tue, 8 Aug 2017 18:03:08 +1000 DMARC-Filter: OpenDMARC Filter v1.3.2 mx1.redhat.com C5E0B883B9 Authentication-Results: ext-mx02.extmail.prod.ext.phx2.redhat.com; dmarc=none (p=none dis=none) header.from=linux.vnet.ibm.com Authentication-Results: ext-mx02.extmail.prod.ext.phx2.redhat.com; spf=fail smtp.mailfrom=libvir-list-bounces@redhat.com DKIM-Filter: OpenDKIM Filter v2.11.0 mx1.redhat.com C5E0B883B9 DMARC-Filter: OpenDMARC Filter v1.3.2 mx1.redhat.com F0F79C0587D3 Authentication-Results: ext-mx08.extmail.prod.ext.phx2.redhat.com; dmarc=none (p=none dis=none) header.from=linux.vnet.ibm.com Authentication-Results: ext-mx08.extmail.prod.ext.phx2.redhat.com; spf=none smtp.mailfrom=kmp@linux.vnet.ibm.com DKIM-Filter: OpenDKIM Filter v2.11.0 mx1.redhat.com F0F79C0587D3 From: Kothapally Madhu Pavan To: libvir-list@redhat.com Date: Tue, 8 Aug 2017 13:32:54 +0530 In-Reply-To: <1502179375-32584-1-git-send-email-kmp@linux.vnet.ibm.com> References: <1502179375-32584-1-git-send-email-kmp@linux.vnet.ibm.com> X-TM-AS-MML: disable x-cbid: 17080808-0040-0000-0000-0000034D3285 X-IBM-AV-DETECTION: SAVI=unused REMOTE=unused XFE=unused x-cbparentid: 17080808-0041-0000-0000-00000CCA58BB Message-Id: <1502179375-32584-7-git-send-email-kmp@linux.vnet.ibm.com> X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10432:, , definitions=2017-08-08_03:, , signatures=0 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 spamscore=0 suspectscore=3 malwarescore=0 phishscore=0 adultscore=0 bulkscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.0.1-1706020000 definitions=main-1708080130 X-Greylist: IP, sender and recipient auto-whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.32]); Tue, 08 Aug 2017 10:41:10 +0000 (UTC) X-Greylist: inspected by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.32]); Tue, 08 Aug 2017 10:41:10 +0000 (UTC) for IP:'148.163.158.5' DOMAIN:'mx0b-001b2d01.pphosted.com' HELO:'mx0a-001b2d01.pphosted.com' FROM:'kmp@linux.vnet.ibm.com' RCPT:'' X-RedHat-Spam-Score: -0.72 (RCVD_IN_DNSWL_LOW, RCVD_IN_MSPIKE_H4, RCVD_IN_MSPIKE_WL) 148.163.158.5 mx0b-001b2d01.pphosted.com 148.163.158.5 mx0b-001b2d01.pphosted.com X-Scanned-By: MIMEDefang 2.78 on 10.5.110.32 X-Scanned-By: MIMEDefang 2.79 on 10.5.11.11 X-loop: libvir-list@redhat.com Cc: Kothapally Madhu Pavan , pkrempa@redhat.com Subject: [libvirt] [PATCH v4 6/7] virsh: Implement managedsave-dumpxml command 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-Scanned-By: MIMEDefang 2.79 on 10.5.11.14 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.26]); Tue, 08 Aug 2017 10:41:17 +0000 (UTC) X-ZohoMail: RSF_0 Z_629925259 SPT_0 Content-Type: text/plain; charset="utf-8" Add a simple virsh command handler which makes use of the new API. Signed-off-by: Kothapally Madhu Pavan --- tools/virsh-domain.c | 56 ++++++++++++++++++++++++++++++++++++++++++++++++= ++++ tools/virsh.pod | 6 ++++++ 2 files changed, 62 insertions(+) diff --git a/tools/virsh-domain.c b/tools/virsh-domain.c index 8baea2a..ce15090 100644 --- a/tools/virsh-domain.c +++ b/tools/virsh-domain.c @@ -4705,6 +4705,56 @@ cmdManagedSaveRemove(vshControl *ctl, const vshCmd *= cmd) } =20 /* + * "managedsave-dumpxml" command + */ +static const vshCmdInfo info_managed_save_dumpxml[] =3D { + {.name =3D "help", + .data =3D N_("Domain information of managed save state file in XML") + }, + {.name =3D "desc", + .data =3D N_("Dump XML of domain information for a managed save state = file to stdout.") + }, + {.name =3D NULL} +}; + +static const vshCmdOptDef opts_managed_save_dumpxml[] =3D { + VIRSH_COMMON_OPT_DOMAIN_FULL, + {.name =3D "security-info", + .type =3D VSH_OT_BOOL, + .help =3D N_("include security sensitive information in XML dump") + }, + {.name =3D NULL} +}; + +static bool +cmdManagedSaveDumpxml(vshControl *ctl, const vshCmd *cmd) +{ + bool ret =3D false; + virDomainPtr dom =3D NULL; + unsigned int flags =3D 0; + char *xml =3D NULL; + + if (vshCommandOptBool(cmd, "security-info")) + flags |=3D VIR_DOMAIN_XML_SECURE; + + dom =3D virshCommandOptDomain(ctl, cmd, NULL); + if (dom =3D=3D NULL) + goto cleanup; + + xml =3D virDomainManagedSaveGetXMLDesc(dom, flags); + if (!xml) + goto cleanup; + + vshPrint(ctl, "%s", xml); + ret =3D true; + + cleanup: + virshDomainFree(dom); + VIR_FREE(xml); + return ret; +} + +/* * "managedsave-define" command */ static const vshCmdInfo info_managed_save_define[] =3D { @@ -13918,6 +13968,12 @@ const vshCmdDef domManagementCmds[] =3D { .info =3D info_managedsaveremove, .flags =3D 0 }, + {.name =3D "managedsave-dumpxml", + .handler =3D cmdManagedSaveDumpxml, + .opts =3D opts_managed_save_dumpxml, + .info =3D info_managed_save_dumpxml, + .flags =3D 0 + }, {.name =3D "managedsave-define", .handler =3D cmdManagedSaveDefine, .opts =3D opts_managed_save_define, diff --git a/tools/virsh.pod b/tools/virsh.pod index 11e2321..1bda44f 100644 --- a/tools/virsh.pod +++ b/tools/virsh.pod @@ -1644,6 +1644,12 @@ running or paused state. Normally, this command doe= s not alter the recorded state; passing either the I<--running> or I<--paused> flag will allow overriding which state the B should use. =20 +=3Ditem B I [I<--security-info>] + +Extract the domain XML that was in effect at the time the saved state +file I was created with the B command. Using +I<--security-info> will also include security sensitive information. + =3Ditem B [I] =20 Provide the maximum number of virtual CPUs supported for a guest VM on --=20 1.8.3.1 -- libvir-list mailing list libvir-list@redhat.com https://www.redhat.com/mailman/listinfo/libvir-list From nobody Sun May 5 19:34:20 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zoho.com: domain of redhat.com designates 209.132.183.28 as permitted sender) client-ip=209.132.183.28; envelope-from=libvir-list-bounces@redhat.com; helo=mx1.redhat.com; Authentication-Results: mx.zohomail.com; spf=pass (zoho.com: domain of redhat.com designates 209.132.183.28 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com Return-Path: Received: from mx1.redhat.com (mx1.redhat.com [209.132.183.28]) by mx.zohomail.com with SMTPS id 1502184586633683.5556816905915; Tue, 8 Aug 2017 02:29:46 -0700 (PDT) Received: from smtp.corp.redhat.com (int-mx01.intmail.prod.int.phx2.redhat.com [10.5.11.11]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id 66B047C84C; Tue, 8 Aug 2017 09:29:44 +0000 (UTC) Received: from colo-mx.corp.redhat.com (colo-mx01.intmail.prod.int.phx2.redhat.com [10.5.11.20]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 955A7908E5; Tue, 8 Aug 2017 09:29:43 +0000 (UTC) Received: from lists01.pubmisc.prod.ext.phx2.redhat.com (lists01.pubmisc.prod.ext.phx2.redhat.com [10.5.19.33]) by colo-mx.corp.redhat.com (Postfix) with ESMTP id 0EF8A1805974; Tue, 8 Aug 2017 09:29:42 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx01.intmail.prod.int.phx2.redhat.com [10.5.11.11]) by lists01.pubmisc.prod.ext.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id v789Teaf014966 for ; Tue, 8 Aug 2017 05:29:40 -0400 Received: by smtp.corp.redhat.com (Postfix) id DDBBD908E4; Tue, 8 Aug 2017 09:29:40 +0000 (UTC) Received: from mx1.redhat.com (ext-mx01.extmail.prod.ext.phx2.redhat.com [10.5.110.25]) by smtp.corp.redhat.com (Postfix) with ESMTPS id D8244908EF for ; Tue, 8 Aug 2017 09:29:36 +0000 (UTC) Received: from mx0a-001b2d01.pphosted.com (mx0a-001b2d01.pphosted.com [148.163.156.1]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id 407267F3E2 for ; Tue, 8 Aug 2017 09:29:34 +0000 (UTC) Received: from pps.filterd (m0098404.ppops.net [127.0.0.1]) by mx0a-001b2d01.pphosted.com (8.16.0.21/8.16.0.21) with SMTP id v7880LpF008690 for ; Tue, 8 Aug 2017 04:03:27 -0400 Received: from e23smtp05.au.ibm.com (e23smtp05.au.ibm.com [202.81.31.147]) by mx0a-001b2d01.pphosted.com with ESMTP id 2c78u0spya-1 (version=TLSv1.2 cipher=AES256-SHA bits=256 verify=NOT) for ; Tue, 08 Aug 2017 04:03:27 -0400 Received: from localhost by e23smtp05.au.ibm.com with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted for from ; Tue, 8 Aug 2017 18:03:25 +1000 Received: from d23relay10.au.ibm.com (202.81.31.229) by e23smtp05.au.ibm.com (202.81.31.211) with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted; Tue, 8 Aug 2017 18:03:21 +1000 Received: from d23av03.au.ibm.com (d23av03.au.ibm.com [9.190.234.97]) by d23relay10.au.ibm.com (8.14.9/8.14.9/NCO v10.0) with ESMTP id v7883LuM36110496; Tue, 8 Aug 2017 18:03:21 +1000 Received: from d23av03.au.ibm.com (localhost [127.0.0.1]) by d23av03.au.ibm.com (8.14.4/8.14.4/NCO v10.0 AVout) with ESMTP id v7883CYm001269; Tue, 8 Aug 2017 18:03:12 +1000 Received: from powerkvmpok002.pok.stglabs.ibm.com (powerkvmpok002.pok.stglabs.ibm.com [9.114.13.10]) by d23av03.au.ibm.com (8.14.4/8.14.4/NCO v10.0 AVin) with ESMTP id v7882nJ1000617; Tue, 8 Aug 2017 18:03:10 +1000 DMARC-Filter: OpenDMARC Filter v1.3.2 mx1.redhat.com 66B047C84C Authentication-Results: ext-mx03.extmail.prod.ext.phx2.redhat.com; dmarc=none (p=none dis=none) header.from=linux.vnet.ibm.com Authentication-Results: ext-mx03.extmail.prod.ext.phx2.redhat.com; spf=fail smtp.mailfrom=libvir-list-bounces@redhat.com DKIM-Filter: OpenDKIM Filter v2.11.0 mx1.redhat.com 66B047C84C DMARC-Filter: OpenDMARC Filter v1.3.2 mx1.redhat.com 407267F3E2 Authentication-Results: ext-mx01.extmail.prod.ext.phx2.redhat.com; dmarc=none (p=none dis=none) header.from=linux.vnet.ibm.com Authentication-Results: ext-mx01.extmail.prod.ext.phx2.redhat.com; spf=none smtp.mailfrom=kmp@linux.vnet.ibm.com DKIM-Filter: OpenDKIM Filter v2.11.0 mx1.redhat.com 407267F3E2 From: Kothapally Madhu Pavan To: libvir-list@redhat.com Date: Tue, 8 Aug 2017 13:32:55 +0530 In-Reply-To: <1502179375-32584-1-git-send-email-kmp@linux.vnet.ibm.com> References: <1502179375-32584-1-git-send-email-kmp@linux.vnet.ibm.com> X-TM-AS-MML: disable x-cbid: 17080808-0016-0000-0000-0000025FBC78 X-IBM-AV-DETECTION: SAVI=unused REMOTE=unused XFE=unused x-cbparentid: 17080808-0017-0000-0000-000006E1C63C Message-Id: <1502179375-32584-8-git-send-email-kmp@linux.vnet.ibm.com> X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10432:, , definitions=2017-08-08_03:, , signatures=0 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 spamscore=0 suspectscore=1 malwarescore=0 phishscore=0 adultscore=0 bulkscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.0.1-1706020000 definitions=main-1708080128 X-Greylist: IP, sender and recipient auto-whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.25]); Tue, 08 Aug 2017 09:29:35 +0000 (UTC) X-Greylist: inspected by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.25]); Tue, 08 Aug 2017 09:29:35 +0000 (UTC) for IP:'148.163.156.1' DOMAIN:'mx0a-001b2d01.pphosted.com' HELO:'mx0a-001b2d01.pphosted.com' FROM:'kmp@linux.vnet.ibm.com' RCPT:'' X-RedHat-Spam-Score: -0.72 (RCVD_IN_DNSWL_LOW, RCVD_IN_MSPIKE_H3, RCVD_IN_MSPIKE_WL) 148.163.156.1 mx0a-001b2d01.pphosted.com 148.163.156.1 mx0a-001b2d01.pphosted.com X-Scanned-By: MIMEDefang 2.78 on 10.5.110.25 X-Scanned-By: MIMEDefang 2.79 on 10.5.11.11 X-loop: libvir-list@redhat.com Cc: Kothapally Madhu Pavan , pkrempa@redhat.com Subject: [libvirt] [PATCH v4 7/7] virsh: Implement managedsave-edit command 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-Scanned-By: MIMEDefang 2.79 on 10.5.11.11 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.27]); Tue, 08 Aug 2017 09:29:45 +0000 (UTC) X-ZohoMail: RSF_0 Z_629925259 SPT_0 Content-Type: text/plain; charset="utf-8" Add a simple virsh command handler which makes use of the new API. Signed-off-by: Kothapally Madhu Pavan --- tools/virsh-domain.c | 72 ++++++++++++++++++++++++++++++++++++++++++++++++= ++++ tools/virsh.pod | 21 +++++++++++++++ 2 files changed, 93 insertions(+) diff --git a/tools/virsh-domain.c b/tools/virsh-domain.c index ce15090..6152661 100644 --- a/tools/virsh-domain.c +++ b/tools/virsh-domain.c @@ -4705,6 +4705,72 @@ cmdManagedSaveRemove(vshControl *ctl, const vshCmd *= cmd) } =20 /* + * "managedsave-edit" command + */ +static const vshCmdInfo info_managed_save_edit[] =3D { + {.name =3D "help", + .data =3D N_("edit XML for a domain's managed save state file") + }, + {.name =3D "desc", + .data =3D N_("Edit the domain XML associated with the managed save sta= te file") + }, + {.name =3D NULL} +}; + +static const vshCmdOptDef opts_managed_save_edit[] =3D { + VIRSH_COMMON_OPT_DOMAIN_FULL, + {.name =3D "running", + .type =3D VSH_OT_BOOL, + .help =3D N_("set domain to be running on start") + }, + {.name =3D "paused", + .type =3D VSH_OT_BOOL, + .help =3D N_("set domain to be paused on start") + }, + {.name =3D NULL} +}; + +static bool +cmdManagedSaveEdit(vshControl *ctl, const vshCmd *cmd) +{ + bool ret =3D false; + virDomainPtr dom =3D NULL; + unsigned int getxml_flags =3D VIR_DOMAIN_XML_SECURE; + unsigned int define_flags =3D 0; + + if (vshCommandOptBool(cmd, "running")) + define_flags |=3D VIR_DOMAIN_SAVE_RUNNING; + if (vshCommandOptBool(cmd, "paused")) + define_flags |=3D VIR_DOMAIN_SAVE_PAUSED; + + VSH_EXCLUSIVE_OPTIONS("running", "paused"); + + dom =3D virshCommandOptDomain(ctl, cmd, NULL); + if (dom =3D=3D NULL) + goto cleanup; + +#define EDIT_GET_XML virDomainManagedSaveGetXMLDesc(dom, getxml_flags) +#define EDIT_NOT_CHANGED = \ + do { = \ + vshPrintExtra(ctl, _("Managed save image of domain %s XML configur= ation " \ + "not changed.\n"), virDomainGetName(dom)); = \ + ret =3D true; = \ + goto edit_cleanup; = \ + } while (0) +#define EDIT_DEFINE \ + (virDomainManagedSaveDefineXML(dom, doc_edited, define_flags) =3D=3D 0) +#include "virsh-edit.c" + + vshPrintExtra(ctl, _("Managed save image of Domain %s XML configuratio= n edited.\n"), + virDomainGetName(dom)); + ret =3D true; + + cleanup: + virshDomainFree(dom); + return ret; +} + +/* * "managedsave-dumpxml" command */ static const vshCmdInfo info_managed_save_dumpxml[] =3D { @@ -13968,6 +14034,12 @@ const vshCmdDef domManagementCmds[] =3D { .info =3D info_managedsaveremove, .flags =3D 0 }, + {.name =3D "managedsave-edit", + .handler =3D cmdManagedSaveEdit, + .opts =3D opts_managed_save_edit, + .info =3D info_managed_save_edit, + .flags =3D 0 + }, {.name =3D "managedsave-dumpxml", .handler =3D cmdManagedSaveDumpxml, .opts =3D opts_managed_save_dumpxml, diff --git a/tools/virsh.pod b/tools/virsh.pod index 1bda44f..dbad9a0 100644 --- a/tools/virsh.pod +++ b/tools/virsh.pod @@ -1650,6 +1650,27 @@ Extract the domain XML that was in effect at the tim= e the saved state file I was created with the B command. Using I<--security-info> will also include security sensitive information. =20 +=3Ditem B I [{I<--running> | I<--paused>}] + +Edit the XML configuration associated with a saved state file of a +I was created by the B command. + +The managed save image records whether the domain should be started to a +running or paused state. Normally, this command does not alter the +recorded state; passing either the I<--running> or I<--paused> flag +will allow overriding which state the B should use. + +This is equivalent to: + + virsh managedsave-dumpxml domain-name > state-file.xml + vi state-file.xml (or make changes with your other text editor) + virsh managedsave-define domain-name state-file-xml + +except that it does some error checking. + +The editor used can be supplied by the C<$VISUAL> or C<$EDITOR> environment +variables, and defaults to C. + =3Ditem B [I] =20 Provide the maximum number of virtual CPUs supported for a guest VM on --=20 1.8.3.1 -- libvir-list mailing list libvir-list@redhat.com https://www.redhat.com/mailman/listinfo/libvir-list