From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:43597) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1X1dvc-0007zJ-CJ for qemu-devel@nongnu.org; Mon, 30 Jun 2014 11:55:42 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1X1dvW-0001jq-6U for qemu-devel@nongnu.org; Mon, 30 Jun 2014 11:55:36 -0400 Received: from mx1.redhat.com ([209.132.183.28]:1874) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1X1dvV-0001jV-KY for qemu-devel@nongnu.org; Mon, 30 Jun 2014 11:55:30 -0400 Message-ID: <53B1886C.1040805@redhat.com> Date: Mon, 30 Jun 2014 09:55:24 -0600 From: Eric Blake MIME-Version: 1.0 References: <20140630145947.GD23599@noname.str.redhat.com> In-Reply-To: <20140630145947.GD23599@noname.str.redhat.com> Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="L1iqAuKtPOulHX2JJluD1G4T713R5g4TF" Subject: Re: [Qemu-devel] [PATCH v7 for 2.1 4/4] block: add QAPI command to allow live backing file change List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Kevin Wolf , Jeff Cody Cc: benoit.canet@irqsave.net, pkrempa@redhat.com, famz@redhat.com, qemu-devel@nongnu.org, stefanha@redhat.com This is an OpenPGP/MIME signed message (RFC 4880 and 3156) --L1iqAuKtPOulHX2JJluD1G4T713R5g4TF Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable On 06/30/2014 08:59 AM, Kevin Wolf wrote: > Am 25.06.2014 um 21:40 hat Jeff Cody geschrieben: >> This allows a user to make a live change to the backing file recorded = in >> an open image. >> >> The image file to modify can be specified 2 ways: >> >> 1) image filename >> 2) image node-name >> > I'm not a huge fan of adding two different addressing modes to a new QM= P > command. I consider using device_name/filename as deprecated and expect= > that management tools use node-name for new commands. Good point. Libvirt does not plan on using this command directly (that is, right now, we don't see a need to change the backing file of an image except as part of a bigger operation; but the work with block-commit and block-stream earlier in this series already adds that in the bigger operation); but we DO want to have a witness that the other commands have support for relative backing name selection. So it is easiest if this new command exists, in ANY form, as the witness that the overall series is in place, without regards to the parameters in this particular command. >=20 > Also there's still Eric's reply and Jeff's promise to update the patch > once blockers were sorted out for 2.1. >=20 > I'm leaning towards declaring this patch not ready. How about a compromise - simplify the command to always require a node-name and device for 2.1. For 2.2, we may later add optional arguments (for example, making @device optional instead of mandatory), and/or provide alternative interfaces (if it turns out we wanted filename addressing after all), but the immediate concern is getting the command installed, with the bare minimum interface. That is, my proposal is to completely drop the addressing by filename, and only allow addressing by node-name. ## # @change-backing-file # # Change the backing file in the image file metadata. This does not # cause QEMU to reopen the image file to reparse the backing filename # (it may, however, perform a reopen to change permissions from # r/o -> r/w -> r/o, if needed). The new backing file string is written # into the image file metadata, and the QEMU internal strings are # updated. # # @image-node-name: The name of the block driver state node of the # image to modify. # # @device: The name of the device that owns image-node-name. # # @backing-file: The string to write as the backing file. This # string is not validated, so care should be taken # when specifying the string or the image chain may # not be able to be reopened again. # # Since: 2.1 ## { 'command': 'change-backing-file', 'data': { 'device': 'str', 'image-node-name': 'str', 'backing-file': 'str' } } --=20 Eric Blake eblake redhat com +1-919-301-3266 Libvirt virtualization library http://libvirt.org --L1iqAuKtPOulHX2JJluD1G4T713R5g4TF Content-Type: application/pgp-signature; name="signature.asc" Content-Description: OpenPGP digital signature Content-Disposition: attachment; filename="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v1 Comment: Public key at http://people.redhat.com/eblake/eblake.gpg Comment: Using GnuPG with Thunderbird - http://www.enigmail.net/ iQEcBAEBCAAGBQJTsYhsAAoJEKeha0olJ0NqvMIH+wYMvNx377SUOZYnFsnM0wVb TJOY515U5OUt+SrKWF1EPqnR1PAgPByDmJZNLmHvjqnqNObn+qO0C52CLliT9lvh zFb857t4o0N0qRsmEr6h3PlB2em3+0py54cvQ5TWg4KYlsCReKBPcVzvPK+Y4ltT A0k18P33HYGMr0FRPE2U02qy8VPj/AMzZon5qnUIMAkSmgDZEGsFm8bCfiLsPaME k9ZKEWLiwQ8G/JRkQa7Kyr/v22cjtDvKlsZPnurZh9HSeyYzCkF52DIJzVPqQRXr M85+0vMyVK2WlIIVWR8Q0URV2Ouf9hZGeNYn93Bmiq6uCLM32wNCPZlWnifIA4c= =ETom -----END PGP SIGNATURE----- --L1iqAuKtPOulHX2JJluD1G4T713R5g4TF--