From nobody Mon Feb 9 00:06:57 2026 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of redhat.com designates 207.211.31.120 as permitted sender) client-ip=207.211.31.120; envelope-from=libvir-list-bounces@redhat.com; helo=us-smtp-1.mimecast.com; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 207.211.31.120 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com; dmarc=pass(p=none dis=none) header.from=redhat.com ARC-Seal: i=1; a=rsa-sha256; t=1585746667; cv=none; d=zohomail.com; s=zohoarc; b=Iyhqwt0sOjXmyoYjX/h+ntPLNSQjbD/typ3wLJykJpyDdNiUqrTLrSqoUC0WL7NW7YCrJ9muHAbGD9s/O+5It+UPZDOZ9UBGoRowigF8BQWJwyyNiBYhCAdukw4WGFke6yAiD9S+ytHOvaNohY2adiAJ5iPa62LJAvs0Fw0yK0A= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1585746667; h=Content-Type:Content-Transfer-Encoding:Date:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:To; bh=dszQHPSXqJflRosuo1yeMfyvRswhl7aiwHiXqg2mJm8=; b=Bvpurp1sV+TLaEe5PnjQK3zFEnT2/Edk33HBUzgHnAV23ze6GffNluj29EV4J46e2NVzQsIC85QRiFa/B2k8wjy1To4paeJGGhbFoUcRMu9KrueCyPYODW2ZMRShVdP8Oj6gDJs34RlkN79bYfdQ+wKHjsMBjLO5Bf0IpgMGgQ8= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 207.211.31.120 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com; dmarc=pass header.from= (p=none dis=none) header.from= Return-Path: Received: from us-smtp-1.mimecast.com (us-smtp-delivery-1.mimecast.com [207.211.31.120]) by mx.zohomail.com with SMTPS id 1585746667686397.9670887546728; Wed, 1 Apr 2020 06:11:07 -0700 (PDT) Received: from mimecast-mx01.redhat.com (mimecast-mx01.redhat.com [209.132.183.4]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-465-IbwMRED6OkWAcm6Hl1tVaA-1; Wed, 01 Apr 2020 09:11:04 -0400 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 mimecast-mx01.redhat.com (Postfix) with ESMTPS id EFFB118A6EC6; Wed, 1 Apr 2020 13:10:58 +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 4DE0B8AC2D; Wed, 1 Apr 2020 13:10: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 D652F86C03; Wed, 1 Apr 2020 13:10:53 +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 031DAqvR001613 for ; Wed, 1 Apr 2020 09:10:52 -0400 Received: by smtp.corp.redhat.com (Postfix) id A259EA63AA; Wed, 1 Apr 2020 13:10:52 +0000 (UTC) Received: from angien.redhat.com (unknown [10.43.2.48]) by smtp.corp.redhat.com (Postfix) with ESMTP id 2679CA63A3 for ; Wed, 1 Apr 2020 13:10:51 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1585746666; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references:list-id:list-help: list-unsubscribe:list-subscribe:list-post; bh=dszQHPSXqJflRosuo1yeMfyvRswhl7aiwHiXqg2mJm8=; b=CgdNfenHHX0Z/tH+rBVXFx8KUB72lm4VvpMWp3j/CA5aVySu5jll5BrnmXz6O/uG6B/OPs ApXDr0Lzme09liZ5EXEscUSvCaor9ZQ9usfMDzAuw+vf4S6C2RujhmrNMUPPlQ9PWVBMEf pGtzJsblaG+1yIVQfRt56SZRa5yUBsc= X-MC-Unique: IbwMRED6OkWAcm6Hl1tVaA-1 From: Peter Krempa To: libvir-list@redhat.com Subject: [PATCH 1/2] qemu: checkpoint: Allow checkpoint redefine for offline VMs Date: Wed, 1 Apr 2020 15:10:46 +0200 Message-Id: In-Reply-To: References: MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.79 on 10.5.11.15 X-loop: libvir-list@redhat.com 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: , 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-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Transfer-Encoding: quoted-printable X-ZohoMail-DKIM: pass (identity @redhat.com) Content-Type: text/plain; charset="utf-8" Skip the liveness and capability checks when redefining checkpoints as we don't need qemu interactions to update the metadata. Signed-off-by: Peter Krempa Reviewed-by: Eric Blake --- src/qemu/qemu_checkpoint.c | 20 +++++++++++--------- 1 file changed, 11 insertions(+), 9 deletions(-) diff --git a/src/qemu/qemu_checkpoint.c b/src/qemu/qemu_checkpoint.c index 3a510c9780..8340addf81 100644 --- a/src/qemu/qemu_checkpoint.c +++ b/src/qemu/qemu_checkpoint.c @@ -647,16 +647,18 @@ qemuCheckpointCreateXML(virDomainPtr domain, update_current =3D false; } - if (!virDomainObjIsActive(vm)) { - virReportError(VIR_ERR_OPERATION_UNSUPPORTED, "%s", - _("cannot create checkpoint for inactive domain")); - return NULL; - } + if (!redefine) { + if (!virDomainObjIsActive(vm)) { + virReportError(VIR_ERR_OPERATION_UNSUPPORTED, "%s", + _("cannot create checkpoint for inactive domain= ")); + return NULL; + } - if (!virQEMUCapsGet(priv->qemuCaps, QEMU_CAPS_INCREMENTAL_BACKUP)) { - virReportError(VIR_ERR_OPERATION_UNSUPPORTED, "%s", - _("incremental backup is not supported yet")); - return NULL; + if (!virQEMUCapsGet(priv->qemuCaps, QEMU_CAPS_INCREMENTAL_BACKUP))= { + virReportError(VIR_ERR_OPERATION_UNSUPPORTED, "%s", + _("incremental backup is not supported yet")); + return NULL; + } } if (!(def =3D virDomainCheckpointDefParseString(xmlDesc, driver->xmlop= t, --=20 2.25.1