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 89DC11FF2AA for ; Wed, 3 Jul 2024 15:07:47 +0200 (CEST) Received: from firstgate.proxmox.com (localhost [127.0.0.1]) by firstgate.proxmox.com (Proxmox) with ESMTP id CD03B8678; Wed, 3 Jul 2024 15:08:03 +0200 (CEST) Message-ID: <20846ad2-3932-41ea-bf16-1bb7270db426@proxmox.com> Date: Wed, 3 Jul 2024 15:08:00 +0200 MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Content-Language: en-US To: Maximiliano Sandoval , PVE development discussion References: <20240527114219.362428-1-m.sandoval@proxmox.com> <3719b558-83e7-41f4-a4c7-3ad3e269dd32@proxmox.com> From: Aaron Lauterer In-Reply-To: X-SPAM-LEVEL: Spam detection results: 0 AWL -0.041 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. [plugin.pm] Subject: Re: [pve-devel] [PATCH storage] 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 Content-Transfer-Encoding: 7bit Content-Type: text/plain; charset="us-ascii"; Format="flowed" Errors-To: pve-devel-bounces@lists.proxmox.com Sender: "pve-devel" On 2024-07-03 14:32, Maximiliano Sandoval wrote: > Aaron Lauterer writes: > >> Works overall. I did not test edge cases like working around the BTRFS plugin to >> have qcow2 files instead of the raw files in a subvol. > > Thanks for testing! > [...] >> I am not too familiar with how BTRFS and our plugin works, but looking at other >> functions, like 'alloc_image' or 'clone_image' it seems that we do have checks >> regarding the format in place. If it is not a 'raw' or 'subvol' we call the >> SUPER from the main Plugin.pm instead of continuing in the BTRFS specific >> implementations that use subvols. >> >> This seems to be missing here, but it might be that it is fine if the "move" is >> working in any way. > > While it is true that others methods call the SUPER method, I didn't > find any other implementation using SUPER::rename_volume. Not surprising, as this behavior seems to be a BTRFS specific one for the edge case that we are dealing with a regular file (non .raw) instead of how the plugin usually wants it. AFAICT this is a safety mechanism, just in case. For example (IIRC): on BTRFS the layout if usually: images/{vmid}/vm-{vmid}-disk-X/disk.raw where the `vm-{vmid}-disk-X` part is a BTRFS subvolume. But it would also be possible that someone (manually) builds it like a regular directory based storage plugin: images/{vmid}/vm-{vmid}-disk-X.qcow2 where everything is just a path/file. How well does the rename_volume code handle this? Or should it call the SUPER method? _______________________________________________ pve-devel mailing list pve-devel@lists.proxmox.com https://lists.proxmox.com/cgi-bin/mailman/listinfo/pve-devel