From nobody Tue Sep 30 03:44:10 2025 Delivered-To: importer@patchew.org Received-SPF: pass (zoho.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Authentication-Results: mx.zohomail.com; spf=pass (zoho.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=fail(p=none dis=none) header.from=gmail.com ARC-Seal: i=1; a=rsa-sha256; t=1561108129; cv=none; d=zoho.com; s=zohoarc; b=dmVIvmu7TqAMWEmLBXtihX01ONM7JMuVnMAaTABxTYM00Wds1+e9S0URZY1WxSZIRy8V70jKST6jIRCVF+03JZbak2VfYK5NHcmh/vhE0z/hkGMbtJouOEhrN1wkVcXJZAhvdaPDo6SBv6qqyfdjM9rxCSmz8Efs1QxgKjgaQos= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zoho.com; s=zohoarc; t=1561108129; h=Content-Type:Content-Transfer-Encoding:Cc: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:ARC-Authentication-Results; bh=woLJi0eBoTgOWu5b82JfPVbadUBgDRHctkII+RZrH/c=; b=h3pdtl9YWAeRu67MUd+w8BP5PXIqXhLym1r7MpOFuv6ikMmJlUYGm6RyzICzp15Tcw9zOnlddIAKegiqTD8AnbYVCsOIyyg1F80x4Ma4wpYpUR1/3erJHBC+Zc2XH0ywP8gl7ia4IvQwwY6mBYwZWTj4jGq6uDtI+qDIDDl661o= ARC-Authentication-Results: i=1; mx.zoho.com; spf=pass (zoho.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=fail header.from= (p=none dis=none) header.from= Return-Path: Received: from lists.gnu.org (209.51.188.17 [209.51.188.17]) by mx.zohomail.com with SMTPS id 1561108129415798.3064388815484; Fri, 21 Jun 2019 02:08:49 -0700 (PDT) Received: from localhost ([::1]:55738 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.86_2) (envelope-from ) id 1heFXH-0007qo-3T for importer@patchew.org; Fri, 21 Jun 2019 05:08:43 -0400 Received: from eggs.gnu.org ([209.51.188.92]:58042) by lists.gnu.org with esmtp (Exim 4.86_2) (envelope-from ) id 1heEzd-00044x-Uq for qemu-devel@nongnu.org; Fri, 21 Jun 2019 04:33:59 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1heEn8-00007p-5V for qemu-devel@nongnu.org; Fri, 21 Jun 2019 04:21:03 -0400 Received: from mail.ispras.ru ([83.149.199.45]:41296) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1heEn7-00006F-VI for qemu-devel@nongnu.org; Fri, 21 Jun 2019 04:21:02 -0400 Received: from [127.0.1.1] (unknown [85.142.117.226]) by mail.ispras.ru (Postfix) with ESMTPSA id 1A47554008B; Fri, 21 Jun 2019 11:21:01 +0300 (MSK) From: Pavel Dovgalyuk To: qemu-devel@nongnu.org Date: Fri, 21 Jun 2019 11:21:00 +0300 Message-ID: <156110526089.25431.13065025960739413137.stgit@pasha-Precision-3630-Tower> In-Reply-To: <156110523748.25431.9310430853468653085.stgit@pasha-Precision-3630-Tower> References: <156110523748.25431.9310430853468653085.stgit@pasha-Precision-3630-Tower> User-Agent: StGit/0.17.1-dirty MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable X-detected-operating-system: by eggs.gnu.org: GNU/Linux 3.x X-Received-From: 83.149.199.45 Subject: [Qemu-devel] [PATCH for-4.1 04/24] replay: update docs for record/replay with block devices X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: kwolf@redhat.com, peter.maydell@linaro.org, pavel.dovgaluk@ispras.ru, pbonzini@redhat.com, quintela@redhat.com, ciro.santilli@gmail.com, jasowang@redhat.com, crosthwaite.peter@gmail.com, armbru@redhat.com, mreitz@redhat.com, alex.bennee@linaro.org, maria.klimushenkova@ispras.ru, mst@redhat.com, kraxel@redhat.com, boost.lists@gmail.com, thomas.dullien@googlemail.com, dovgaluk@ispras.ru, artem.k.pisarenko@gmail.com, dgilbert@redhat.com, rth@twiddle.net Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: "Qemu-devel" From: Pavel Dovgalyuk This patch updates the description of the command lines for using record/replay with attached block devices. Signed-off-by: Pavel Dovgalyuk --- docs/replay.txt | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) diff --git a/docs/replay.txt b/docs/replay.txt index ee6aee9861..ce97c3f72f 100644 --- a/docs/replay.txt +++ b/docs/replay.txt @@ -27,7 +27,7 @@ Usage of the record/replay: * First, record the execution with the following command line: qemu-system-i386 \ -icount shift=3D7,rr=3Drecord,rrfile=3Dreplay.bin \ - -drive file=3Ddisk.qcow2,if=3Dnone,id=3Dimg-direct \ + -drive file=3Ddisk.qcow2,if=3Dnone,snapshot,id=3Dimg-direct \ -drive driver=3Dblkreplay,if=3Dnone,image=3Dimg-direct,id=3Dimg-blkre= play \ -device ide-hd,drive=3Dimg-blkreplay \ -netdev user,id=3Dnet1 -device rtl8139,netdev=3Dnet1 \ @@ -35,7 +35,7 @@ Usage of the record/replay: * After recording, you can replay it by using another command line: qemu-system-i386 \ -icount shift=3D7,rr=3Dreplay,rrfile=3Dreplay.bin \ - -drive file=3Ddisk.qcow2,if=3Dnone,id=3Dimg-direct \ + -drive file=3Ddisk.qcow2,if=3Dnone,snapshot,id=3Dimg-direct \ -drive driver=3Dblkreplay,if=3Dnone,image=3Dimg-direct,id=3Dimg-blkre= play \ -device ide-hd,drive=3Dimg-blkreplay \ -netdev user,id=3Dnet1 -device rtl8139,netdev=3Dnet1 \ @@ -223,7 +223,7 @@ Block devices record/replay module intercepts calls of bdrv coroutine functions at the top of block drivers stack. To record and replay block operations the drive must be configured as following: - -drive file=3Ddisk.qcow2,if=3Dnone,id=3Dimg-direct + -drive file=3Ddisk.qcow2,if=3Dnone,snapshot,id=3Dimg-direct -drive driver=3Dblkreplay,if=3Dnone,image=3Dimg-direct,id=3Dimg-blkreplay -device ide-hd,drive=3Dimg-blkreplay =20 @@ -252,6 +252,12 @@ This snapshot is created at start of recording and res= tored at start of replaying. It also can be loaded while replaying to roll back the execution. =20 +'snapshot' flag of the disk image must be removed to save the snapshots +in the overlay (or original image) instead of using the temporary overlay. + -drive file=3Ddisk.ovl,if=3Dnone,id=3Dimg-direct + -drive driver=3Dblkreplay,if=3Dnone,image=3Dimg-direct,id=3Dimg-blkreplay + -device ide-hd,drive=3Dimg-blkreplay + Use QEMU monitor to create additional snapshots. 'savevm ' command created the snapshot and 'loadvm ' restores it. To prevent corruption of the original disk image, use overlay files linked to the original image= s.