From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from firstgate.proxmox.com (firstgate.proxmox.com [IPv6:2a01:7e0:0:424::9]) by lore.proxmox.com (Postfix) with ESMTPS id 9AD6D1FF2B0 for ; Fri, 5 Jul 2024 14:57:20 +0200 (CEST) Received: from firstgate.proxmox.com (localhost [127.0.0.1]) by firstgate.proxmox.com (Proxmox) with ESMTP id BAF3D2E80; Fri, 5 Jul 2024 14:57:35 +0200 (CEST) Message-ID: Date: Fri, 5 Jul 2024 14:57:31 +0200 MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Content-Language: en-US To: Maximiliano Sandoval References: <20240704120213.351520-1-m.sandoval@proxmox.com> <16f29fdd-8a9c-4c7f-8fdd-8664d0a2c041@proxmox.com> From: Aaron Lauterer In-Reply-To: X-SPAM-LEVEL: Spam detection results: 0 AWL -0.291 Adjusted score from AWL reputation of From: address BAYES_00 -1.9 Bayes spam probability is 0 to 1% DMARC_MISSING 0.1 Missing DMARC policy KAM_DMARC_STATUS 0.01 Test Rule for DKIM or SPF Failure with Strict Alignment 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. [btrfsplugin.pm] URI_NOVOWEL 0.5 URI hostname has long non-vowel sequence Subject: Re: [pve-devel] [PATCH storage v3] fix #4272: btrfs: add rename feature 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: , Reply-To: Proxmox VE development discussion Cc: Proxmox VE development discussion Content-Transfer-Encoding: 7bit Content-Type: text/plain; charset="us-ascii"; Format="flowed" Errors-To: pve-devel-bounces@lists.proxmox.com Sender: "pve-devel" Without my changes I get the following error when I try to do it with the manually places qcow2 file: Storage does not support moving of this disk to another VM (500) And if I enable qcow2 for the rename feature without adding the format check in the rename_volume function: diff --git a/src/PVE/Storage/BTRFSPlugin.pm b/src/PVE/Storage/BTRFSPlugin.pm index 7376ae4..56730d1 100644 --- a/src/PVE/Storage/BTRFSPlugin.pm +++ b/src/PVE/Storage/BTRFSPlugin.pm @@ -619,7 +619,7 @@ sub volume_has_feature { current => { qcow2 => 1, raw => 1, vmdk => 1 }, }, rename => { - current => { raw => 1 }, + current => { qcow2 => 1, raw => 1 }, }, }; it fails with the following error: internal error: bad disk name: 104/vm-104-disk-1.qcow2 at /usr/share/perl5/PVE/Storage/BTRFSPlugin.pm: 951 On 2024-07-05 14:41, Maximiliano Sandoval wrote: > Aaron Lauterer writes: > >> gave it a try and it does what it should. >> by enabling the rename feature only for `raw` we avoid potential pitfalls if we >> encounter a non regular situation on BTRFS. For example, an >> images/{vmid}/vm-{vmid}-disk-X.qcow2 file directly instead of the >> images/{vmid}/vm-{vmid}-disk-X/disk.raw as is the way the BTRFS plugin handles >> it in subvolumes. >> >> But if we add the following diff, it seems to handle the case of a qcow2 file in >> the same directory structure just fine: > > Did you try it without your patch? I tested it here and it seemed to > work from my limited testing. > _______________________________________________ pve-devel mailing list pve-devel@lists.proxmox.com https://lists.proxmox.com/cgi-bin/mailman/listinfo/pve-devel