From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from firstgate.proxmox.com (firstgate.proxmox.com [212.224.123.68]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits)) (No client certificate requested) by lists.proxmox.com (Postfix) with ESMTPS id 681C56D1C6 for ; Thu, 4 Feb 2021 11:26:41 +0100 (CET) Received: from firstgate.proxmox.com (localhost [127.0.0.1]) by firstgate.proxmox.com (Proxmox) with ESMTP id 5AAF622A77 for ; Thu, 4 Feb 2021 11:26:11 +0100 (CET) Received: from proxmox-new.maurer-it.com (proxmox-new.maurer-it.com [212.186.127.180]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits)) (No client certificate requested) by firstgate.proxmox.com (Proxmox) with ESMTPS id 4C92322A6D for ; Thu, 4 Feb 2021 11:26:10 +0100 (CET) Received: from proxmox-new.maurer-it.com (localhost.localdomain [127.0.0.1]) by proxmox-new.maurer-it.com (Proxmox) with ESMTP id 14287461E0 for ; Thu, 4 Feb 2021 11:26:10 +0100 (CET) From: Fabian Ebner To: pve-devel@lists.proxmox.com Date: Thu, 4 Feb 2021 11:26:06 +0100 Message-Id: <20210204102606.17447-1-f.ebner@proxmox.com> X-Mailer: git-send-email 2.20.1 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-SPAM-LEVEL: Spam detection results: 0 AWL -0.004 Adjusted score from AWL reputation of From: address KAM_DMARC_STATUS 0.01 Test Rule for DKIM or SPF Failure with Strict Alignment RCVD_IN_DNSWL_MED -2.3 Sender listed at https://www.dnswl.org/, medium trust SPF_HELO_NONE 0.001 SPF: HELO does not publish an SPF Record SPF_PASS -0.001 SPF: sender matches SPF record URIBL_BLOCKED 0.001 ADMINISTRATOR NOTICE: The query to URIBL was blocked. See http://wiki.apache.org/spamassassin/DnsBlocklists#dnsbl-block for more information. [glusterfsplugin.pm, plugin.pm] Subject: [pve-devel] [PATCH storage] clone image: specify base format option with qemu-img X-BeenThere: pve-devel@lists.proxmox.com X-Mailman-Version: 2.1.29 Precedence: list List-Id: Proxmox VE development discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 04 Feb 2021 10:26:41 -0000 and avoid a warning. It is deprecated to auto-detect the format of the base volume. See commit d9f059aa6cfccefaffa3532556e966df4a99ece2 in qemu for more information. Signed-off-by: Fabian Ebner --- PVE/Storage/GlusterfsPlugin.pm | 2 +- PVE/Storage/Plugin.pm | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/PVE/Storage/GlusterfsPlugin.pm b/PVE/Storage/GlusterfsPlugin.pm index 2dd414d..5ec2f42 100644 --- a/PVE/Storage/GlusterfsPlugin.pm +++ b/PVE/Storage/GlusterfsPlugin.pm @@ -228,7 +228,7 @@ sub clone_image { my $volumepath = "gluster://$server/$glustervolume/images/$vmid/$name"; my $cmd = ['/usr/bin/qemu-img', 'create', '-b', "../$basevmid/$basename", - '-f', 'qcow2', $volumepath]; + '-F', $format, '-f', 'qcow2', $volumepath]; run_command($cmd, errmsg => "unable to create image"); diff --git a/PVE/Storage/Plugin.pm b/PVE/Storage/Plugin.pm index d2d8184..bd8b345 100644 --- a/PVE/Storage/Plugin.pm +++ b/PVE/Storage/Plugin.pm @@ -708,7 +708,7 @@ sub clone_image { local $CWD = $imagedir; my $cmd = ['/usr/bin/qemu-img', 'create', '-b', "../$basevmid/$basename", - '-f', 'qcow2', $path]; + '-F', $format, '-f', 'qcow2', $path]; run_command($cmd); }; -- 2.20.1