Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.debian.user > #274910

Re: The "uniqueness" of UUIDs

From <tomas@tuxteam.de>
Newsgroups linux.debian.user
Subject Re: The "uniqueness" of UUIDs
Date 2024-11-26 18:50 +0100
Message-ID <JN7Rf-bNLD-3@gated-at.bofh.it> (permalink)
References (4 earlier) <JMZAl-bIAy-5@gated-at.bofh.it> <JN4gF-bLwC-5@gated-at.bofh.it> <JN5cK-bM7e-11@gated-at.bofh.it> <JN5cK-bM7e-9@gated-at.bofh.it> <JN5Pr-bMzv-9@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


[Multipart message — attachments visible in raw view] - view raw

On Tue, Nov 26, 2024 at 04:35:13PM +0100, Roger Price wrote:
> On Tue, 26 Nov 2024, tomas@tuxteam.de wrote:
> 
> > On Tue, Nov 26, 2024 at 03:53:28PM +0100, Roger Price wrote:
> > > "except via mdadm" : exactly the point I would like to make.  mdadm needs to
> > > be able to address the individual underlying devices.  Only /dev/sdxn style
> > > addressing can do this, not duplicate UUIDs, or duplicate LABELs.
> > 
> > If those we are talking about are file system UUIDs/LABELs (and all evidence
> > supports that), they *are not* duplicate. They are *the same*. Change "one"
> > and *poof* the "other" will change along. Because they are on the file system,
> > which is sitting astride your MD devices.
> 
> My understanding is that a Linux file system is a hierachical structure
> starting with the root directory (/) which organises the directories and
> files.  The files are stored on various devices which have identities such
> as /dev/sdxn, UUID or LABEL.  These identities are for the devices, not
> parts of the file system.

File system is indeed ambiguous here. In this context it was meant as
the data structure existing in a block device organizing its files.

For example, in my case:

  tomas@caliban:~$ lsblk
  NAME                   MAJ:MIN RM  SIZE RO TYPE  MOUNTPOINTS
  sda                      8:0    0  1.8T  0 disk  
  ├─sda1                   8:1    0  512M  0 part  /boot/efi
  ├─sda2                   8:2    0  488M  0 part  /boot
  └─sda3                   8:3    0  1.8T  0 part  
    └─sda3_crypt         254:0    0  1.8T  0 crypt 
      ├─caliban--vg-root 254:1    0 23.3G  0 lvm   /
      ├─caliban--vg-home 254:2    0  1.6T  0 lvm   /home
      ├─caliban--vg-var  254:3    0  160G  0 lvm   /var
      └─caliban--vg-tmp  254:4    0 40.3G  0 lvm   /tmp

all of /dev/sda1, /dev/sda2, /dev/mapper/caliban--vg-root (which is
actually /dev/dm-1, but let's pretend) and so on have a file system
on them; most of them actually ext4, except /dev/sda2, which is ext2,
and /dev/sda1, which is vfat (as efi, it has to).

Thanks to mount, their file system trees are grafted together into
one single big file system tree (what you rightfully call "the file
system" above).

> The file system and the underlying devices are separate notions, which is
> why I don't understand your phrase "file system UUIDs/LABELs".

Each of those file systems has a slot for a label. Ext has also a slot for
an UUID, which gets generated afresh whenever you mkfs.ext. ISTR that the
FATs don't have that, but I'm too lazy to look it up now.

Here [1] is the ext4 superblock structure: at offsets 0x68 and 0x78 you
can find the places for the UUID and the name, aka label.

Cheers
[1] https://www.kernel.org/doc/html/latest/filesystems/ext4/globals.html
-- 
t

Back to linux.debian.user | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread


Thread

Re: Adding a new boot disk while keeping old disk George at Clug <Clug@goproject.info> - 2024-11-25 08:30 +0100
  Re: Adding a new boot disk while keeping old disk eben@gmx.us - 2024-11-25 16:10 +0100
    Re: Adding a new boot disk while keeping old disk David Wright <deblis@lionunicorn.co.uk> - 2024-11-25 16:30 +0100
      Re: Adding a new boot disk while keeping old disk Felix Miata <mrmazda@stanis.net> - 2024-11-25 16:40 +0100
        Re: Adding a new boot disk while keeping old disk George at Clug <Clug@goproject.info> - 2024-11-26 01:50 +0100
          The "uniqueness" of UUIDs Roger Price <debian@rogerprice.org> - 2024-11-26 09:00 +0100
            Re: The "uniqueness" of UUIDs Nicolas George <george@nsup.org> - 2024-11-26 09:10 +0100
              Re: The "uniqueness" of UUIDs Nicolas George <george@nsup.org> - 2024-11-26 09:40 +0100
              Re: The "uniqueness" of UUIDs Roger Price <debian@rogerprice.org> - 2024-11-26 09:50 +0100
            Re: The "uniqueness" of UUIDs Felix Miata <mrmazda@stanis.net> - 2024-11-26 09:30 +0100
              Re: The "uniqueness" of UUIDs Roger Price <debian@rogerprice.org> - 2024-11-26 10:00 +0100
                Re: The "uniqueness" of UUIDs Nicolas George <george@nsup.org> - 2024-11-26 10:10 +0100
                Re: The "uniqueness" of UUIDs Roger Price <debian@rogerprice.org> - 2024-11-26 12:20 +0100
                Re: The "uniqueness" of UUIDs <tomas@tuxteam.de> - 2024-11-26 12:40 +0100
                Re: The "uniqueness" of UUIDs Nicolas George <george@nsup.org> - 2024-11-26 12:40 +0100
                Re: The "uniqueness" of UUIDs <tomas@tuxteam.de> - 2024-11-26 10:30 +0100
                Re: The "uniqueness" of UUIDs Nicolas George <george@nsup.org> - 2024-11-26 11:00 +0100
                Re: The "uniqueness" of UUIDs Felix Miata <mrmazda@stanis.net> - 2024-11-26 15:00 +0100
                Re: The "uniqueness" of UUIDs <tomas@tuxteam.de> - 2024-11-26 16:00 +0100
                Re: The "uniqueness" of UUIDs Roger Price <debian@rogerprice.org> - 2024-11-26 16:40 +0100
                Re: The "uniqueness" of UUIDs <tomas@tuxteam.de> - 2024-11-26 18:50 +0100
                Re: The "uniqueness" of UUIDs Michael Stone <mstone@debian.org> - 2024-11-27 18:00 +0100
                Re: The "uniqueness" of UUIDs Roger Price <debian@rogerprice.org> - 2024-11-26 16:00 +0100
            Re: The "uniqueness" of UUIDs Arno Lehmann <al@its-lehmann.de> - 2024-11-26 09:30 +0100
              Re: The "uniqueness" of UUIDs Arno Lehmann <al@its-lehmann.de> - 2024-11-26 10:50 +0100
            Re: The "uniqueness" of UUIDs <tomas@tuxteam.de> - 2024-11-26 09:50 +0100
            Re: The "uniqueness" of UUIDs pocket@homemail.com - 2024-11-26 13:20 +0100
      Re: Adding a new boot disk while keeping old disk eben@gmx.us - 2024-11-25 18:30 +0100
        Re: Adding a new boot disk while keeping old disk Hans <hans.ullrich@loop.de> - 2024-11-25 21:00 +0100
    Re: Adding a new boot disk while keeping old disk <tomas@tuxteam.de> - 2024-11-25 18:00 +0100
      Re: Adding a new boot disk while keeping old disk Default User <hunguponcontent@gmail.com> - 2024-11-25 18:40 +0100
        Re: Adding a new boot disk while keeping old disk <tomas@tuxteam.de> - 2024-11-25 19:00 +0100
          Re: Adding a new boot disk while keeping old disk Default User <hunguponcontent@gmail.com> - 2024-11-25 20:10 +0100
        Re: Adding a new boot disk while keeping old disk eben@gmx.us - 2024-11-25 23:40 +0100
          Re: Adding a new boot disk while keeping old disk Greg Wooledge <greg@wooledge.org> - 2024-11-26 00:00 +0100
            Re: Adding a new boot disk while keeping old disk Felix Miata <mrmazda@stanis.net> - 2024-11-26 00:30 +0100
      Re: Adding a new boot disk while keeping old disk Max Nikulin <manikulin@gmail.com> - 2024-11-26 03:40 +0100

csiph-web