From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 2155) id 3B33B3870924; Thu, 23 Nov 2023 16:27:50 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 3B33B3870924 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=cygwin.com; s=default; t=1700756870; bh=/x2HEZb37ZO8BmrhbRpnA6K4xRSROQFRG8Xmj29Z8uc=; h=Date:From:To:Subject:Reply-To:References:In-Reply-To:From; b=r7OVEUY1bwSEdgzRfA3DV8FJMkYt9XiO8SWgtIMzkqbp7EEYWLj4TDqMdrKUts6cL HP7zMs7DZ48DTt7DW1hDRmEYrLxmEU/I+smA4n7pOlJp1MD65wha7v0PsYfz2au/LS 6tgkPW+8wCN9GeCZm01FDTXZjCeNgjGlVRZwCzgk= Received: by calimero.vinschen.de (Postfix, from userid 500) id 4FEC9A80B9F; Thu, 23 Nov 2023 17:27:48 +0100 (CET) Date: Thu, 23 Nov 2023 17:27:48 +0100 From: Corinna Vinschen To: cygwin-patches@cygwin.com Subject: Re: [PATCH] Cygwin: Add /dev/disk/by-label and /dev/disk/by-uuid symlinks Message-ID: Reply-To: cygwin-patches@cygwin.com Mail-Followup-To: cygwin-patches@cygwin.com References: <0f8c8b7e-8a67-bc0a-24c3-91d28e2f0972@t-online.de> <0ba1c78e-15e6-65a2-eb4d-16ac2495c356@t-online.de> <7d24b7f1-0dae-ad23-6bde-3502716edbad@t-online.de> <6502e361-6b64-418e-d041-93cf4810f083@t-online.de> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline In-Reply-To: <6502e361-6b64-418e-d041-93cf4810f083@t-online.de> List-Id: On Nov 22 17:31, Christian Franke wrote: > Hi Corinna, > > Corinna Vinschen wrote: > > Hi Christian, > > > > > > On second thought... > > > > I had a bad night tonight and was thinking a long time about this and > > that. It suddenly occured to me that there might be another problem > > with this approach, attaching ordinals to the label name. > > > > Assuming you have a single filesystem labled "VOLUME" which is on a > > fixed disk. So you get something like this: > > > > $ ls -l /dev/disk/by-label > > total 0 > > lrwxrwxrwx 1 corinna vinschen 0 Nov 22 10:09 VOLUME -> ../../sdb1 > > lrwxrwxrwx 1 corinna vinschen 0 Nov 22 10:10 root -> ../../sda3 > > > > Now you insert an USB Stick with a FAT32 filesystem, also labeled > > "VOLUME". Now you get something like this: > > > > $ ls -l /dev/disk/by-label > > total 0 > > lrwxrwxrwx 1 corinna vinschen 0 Nov 22 10:12 'VOLUME#0' -> ../../sdb1 > > lrwxrwxrwx 1 corinna vinschen 0 Nov 22 10:12 'VOLUME#1' -> ../../sdc1 > > lrwxrwxrwx 1 corinna vinschen 0 Nov 22 10:10 root -> ../../sda3 > > > > So the label name changes, depending on inserting or removing another > > partition. > > This is intentional. If the first duplicate appears, it is IMO better to > also replace the original name to show that a duplicate exists. > > > > > > Not saying I have a good solution myself, so I wonder if we should just > > let it slip, but I thought we should at least talk about it... > > Users should be aware that unspecific label names like VOLUME could not be > used as a persistent link if drives are changed. > > Same may apply to by-partuuid names as preformatted SD-cards and USB flash > drives may have a null MBR serial number. Makes total sense. Thanks, Corinna