[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Understanding LVM UUIDS



On 07/02/2010 12:40 PM, Daniel Barclay wrote:
Aaron Toponce wrote:

UUIDs are unique to the device/filesystem.

Are these (disk) UUIDs stored somewhere in the partition (in the
filesystem), or are they stored at or generated from a lower level?

In the superblock.

# dumpe2fs -h /dev/mapper/main_huge_vg-main_huge_lv
dumpe2fs 1.41.12 (17-May-2010)
Filesystem volume name:   BIG_LV
Last mounted on:          /data/big
Filesystem UUID:          4efe50a9-0915-4022-8446-a036607492b7
Filesystem magic number:  0xEF53
Filesystem revision #:    1 (dynamic)
Filesystem features: has_journal ext_attr resize_inode dir_index filetype needs_recovery extent flex_bg sparse_super large_file huge_file uninit_bg dir_nlink extra_isize
Filesystem flags:         signed_directory_hash
Default mount options:    (none)
Filesystem state:         clean
Errors behavior:          Continue
Filesystem OS type:       Linux
Inode count:              241491968
Block count:              965967872
Reserved block count:     48298393
Free blocks:              323162178
Free inodes:              241184065
First block:              0
Block size:               4096
Fragment size:            4096
Reserved GDT blocks:      793
Blocks per group:         32768
Fragments per group:      32768
Inodes per group:         8192
Inode blocks per group:   512
Flex block group size:    16
Filesystem created:       Thu Jul 23 19:32:26 2009
Last mount time:          Sat May 29 08:46:56 2010
Last write time:          Sat May 29 08:46:56 2010
Mount count:              4
Maximum mount count:      26
Last checked:             Sat May  8 21:02:48 2010
Check interval:           15552000 (6 months)
Next check after:         Thu Nov  4 21:02:48 2010
Lifetime writes:          1825 GB
Reserved blocks uid:      0 (user root)
Reserved blocks gid:      0 (group root)
First inode:              11
Inode size:	          256
Required extra isize:     28
Desired extra isize:      28
Journal inode:            8
Default directory hash:   half_md4
Directory Hash Seed:      1a030567-e52e-4f1e-bc60-31a288283802
Journal backup:           inode blocks
Journal features:         journal_incompat_revoke
Journal size:             128M
Journal length:           32768
Journal sequence:         0x00032ed5
Journal start:            12599


In particular, if one used dd to copy the contents (a file system) of
one partition to another partition, does the target partition end up
with the same UUID or a different UUID? If you did a byte-for-byte
copy of an entire disk to another disk of the exact same size (and
model, but different serial number), would the UUIDs of partitions
change or still be the same on the target disk?)

(Is it similar to, or different than, the situation with filesystem
labels (specifically, that if you copied a partition as above you'd
end up with two partitions with the same label, and you'd have to
change one (or otherwise deal with the non-uniqueness))?)

Thanks,
Daniel




--
Seek truth from facts.


Reply to: