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 9B0E08AA88 for ; Fri, 19 Aug 2022 11:29:59 +0200 (CEST) Received: from firstgate.proxmox.com (localhost [127.0.0.1]) by firstgate.proxmox.com (Proxmox) with ESMTP id 9090618A2E for ; Fri, 19 Aug 2022 11:29:59 +0200 (CEST) Received: from proxmox-new.maurer-it.com (proxmox-new.maurer-it.com [94.136.29.106]) (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 for ; Fri, 19 Aug 2022 11:29:59 +0200 (CEST) Received: from proxmox-new.maurer-it.com (localhost.localdomain [127.0.0.1]) by proxmox-new.maurer-it.com (Proxmox) with ESMTP id E0C894344A for ; Fri, 19 Aug 2022 11:29:58 +0200 (CEST) Message-ID: <6d75b24d-6d97-26b0-d6d3-0d92f47344e5@proxmox.com> Date: Fri, 19 Aug 2022 11:29:58 +0200 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Thunderbird/102.1.2 Content-Language: en-US To: pve-devel@lists.proxmox.com References: <20220715115808.1385388-1-a.lauterer@proxmox.com> <20220715115808.1385388-3-a.lauterer@proxmox.com> <1660736115.7grkvr18dc.astroid@nora.none> <3c556291-e140-1623-6b0d-eeb2920aab30@proxmox.com> <1660897234.79lpydl84s.astroid@nora.none> From: Aaron Lauterer In-Reply-To: <1660897234.79lpydl84s.astroid@nora.none> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit X-SPAM-LEVEL: Spam detection results: 0 AWL -0.014 Adjusted score from AWL reputation of From: address BAYES_00 -1.9 Bayes spam probability is 0 to 1% KAM_DMARC_STATUS 0.01 Test Rule for DKIM or SPF Failure with Strict Alignment NICE_REPLY_A -0.001 Looks like a legit reply (A) SPF_HELO_NONE 0.001 SPF: HELO does not publish an SPF Record SPF_PASS -0.001 SPF: sender matches SPF record T_SCC_BODY_TEXT_LINE -0.01 - Subject: Re: [pve-devel] [PATCH storage v2 2/3] disks: die if storage name is already in use 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: Fri, 19 Aug 2022 09:29:59 -0000 On 8/19/22 10:21, Fabian Grünbichler wrote: > On August 18, 2022 5:31 pm, Aaron Lauterer wrote: >> >> >> On 8/18/22 17:22, Aaron Lauterer wrote: >>> >>> >>> On 8/17/22 13:42, Fabian Grünbichler wrote:[..] >>>>> +    die "a systemd mount unit already exists: ${mountunitpath}\n" if -e >>>>> $mountunitpath; >>>> >>>> could check if it's identical to the one we'd generate (in the spirit of >>>> patch #3 ;)) >>> >>> I looked into it, depending on how hard we want to match the mount unit, this >>> could be a bit hard. It contains the /dev/disk/by-uuid/... path which will not >>> be the same as it changes with each FS creation (IIUC). >> >> The question is, if it is a good idea to have the check since there is no easy >> way for the user to remedy the problem without doing a manual `rm >> /etc/systemd/system/foo.mount`. > > *could* be solved by having a force parameter I guess? not sure that's a > good idea, just throwing it out there ;) > a short off list discussion brought up that we indeed can remove dangling mount units already, so keeping the check is okay since users can quite easily remove it