On Tue, 2015-06-16 at 11:30 +0100, John Hodrien wrote:> On Tue, 16 Jun 2015, Always Learning wrote: > > > ON Centos 5, using GPARTED I created partitions for filing systems ext3 > > and ext4. 4 primary and unlimited (except by space) extended partitions. > > That suggests those partitions are not GPT but old fashioned M$DOS > > If it is old fashioned MSDOS, you can have four total primary and extended, > not four primary plus extended. An extended partition then provides a > container for further logical partitions.Yes you are correct. Maximum 4 primary or maximum 3 primary and 1 extended which is then sub-divided into more partitions.> LUKS provides a UUID, so being encrypted isn't a barrier to having a UUID.But my point was M$ DOS partitions, not being GPT partitions, can have UUIDs. The original poster appeared to suggest that was not possible. He wrote> > Non-GPT partitions do not have a UUID. The _content_ (filesystem, > > LVM physical volume, non-encrypted swap space, etc.) of such a > > partition could have a UUID, but the partition itself does not.When I think I am mounting a M$ DOS partition, am I mounting a real partition or merely 'the file system' within that partition ? Some may think one can't have one without the other. -- Regards, Paul. England, EU. England's place is in the European Union.
On Tue, 16 Jun 2015, Always Learning wrote:> But my point was M$ DOS partitions, not being GPT partitions, can have > UUIDs. The original poster appeared to suggest that was not possible.No, the partition there does not have a UUID. Run fdisk, create a partition, dd if=/dev/zero of=/dev/sda4 blkid You'll see no UUID, as the partition does not provide a UUID, and there's nothing on it to provide a UUID. Format it, or make some swap space or whatever, and you get a UUID.> When I think I am mounting a M$ DOS partition, am I mounting a real > partition or merely 'the file system' within that partition ? Some may > think one can't have one without the other.You never mount a partition, only a filesystem. The partition merely points you to where the filesystem is. jh
On 16 Jun 2015 12:12, "Always Learning" <centos at u64.u22.net> wrote:> > > On Tue, 2015-06-16 at 11:30 +0100, John Hodrien wrote: > > On Tue, 16 Jun 2015, Always Learning wrote: > > > > > ON Centos 5, using GPARTED I created partitions for filing systemsext3> > > and ext4. 4 primary and unlimited (except by space) extendedpartitions.> > > That suggests those partitions are not GPT but old fashioned M$DOS > > > > If it is old fashioned MSDOS, you can have four total primary andextended,> > not four primary plus extended. An extended partition then provides a > > container for further logical partitions. > > Yes you are correct. Maximum 4 primary or maximum 3 primary and 1 > extended which is then sub-divided into more partitions. > > > LUKS provides a UUID, so being encrypted isn't a barrier to having aUUID.> > But my point was M$ DOS partitions, not being GPT partitions, can have > UUIDs. The original poster appeared to suggest that was not possible. He > wrote >Those were filesystem UUIDs not partition UUIDs ... LUKS has its own header similar to ext4, lvm, etc headers which has a UUID in it. This UUID being associated with the LUKS header indicates it is not a partition UUID. A dd of this (or lvm snapshot) to another partition will keep the same UUID. A partition UUID within a GPT table would not be persisted in this manner, and msdos labeled disks have no concept of this to begin with.> > > Non-GPT partitions do not have a UUID. The _content_ (filesystem, > > > LVM physical volume, non-encrypted swap space, etc.) of such a > > > partition could have a UUID, but the partition itself does not. > > When I think I am mounting a M$ DOS partition, am I mounting a real > partition or merely 'the file system' within that partition ? Some may > think one can't have one without the other. > >Of course you can have a partition or filesystem without the other. This is how raw devices work and you can mkfs a block device with no partitions. When you mount something you mount the filesystem.
On 06/16/2015 06:43 AM, James Hogarth wrote:> On 16 Jun 2015 12:12, "Always Learning" <centos at u64.u22.net> wrote: >> >> >> On Tue, 2015-06-16 at 11:30 +0100, John Hodrien wrote: >>> On Tue, 16 Jun 2015, Always Learning wrote: >>> >>>> ON Centos 5, using GPARTED I created partitions for filing systems > ext3 >>>> and ext4. 4 primary and unlimited (except by space) extended > partitions. >>>> That suggests those partitions are not GPT but old fashioned M$DOS >>> >>> If it is old fashioned MSDOS, you can have four total primary and > extended, >>> not four primary plus extended. An extended partition then provides a >>> container for further logical partitions. >> >> Yes you are correct. Maximum 4 primary or maximum 3 primary and 1 >> extended which is then sub-divided into more partitions. >> >>> LUKS provides a UUID, so being encrypted isn't a barrier to having a > UUID. >> >> But my point was M$ DOS partitions, not being GPT partitions, can have >> UUIDs. The original poster appeared to suggest that was not possible. He >> wrote >> > > Those were filesystem UUIDs not partition UUIDs ...LUKS physical volume UUIDs, actually. When you create a LUKS logical volume within that PV, it also has a UUID, and a filesystem within that LUKS LV will have its own UUID. These are all part of the partition's _content_. A GPT partition has its own UUID, independent of the partition's content. An MSDOS partition does not.> LUKS has its own header similar to ext4, lvm, etc headers which has a UUID > in it. > > This UUID being associated with the LUKS header indicates it is not a > partition UUID. > > A dd of this (or lvm snapshot) to another partition will keep the same UUID.Indeed. If your version of cryptsetup is new enough (supports the "--header" option), try doing the luksFormat operation with a detached header. Now you will find that your LUKS partition no longer has a UUID.> A partition UUID within a GPT table would not be persisted in this manner, > and msdos labeled disks have no concept of this to begin with.-- Bob Nichols "NOSPAM" is really part of my email address. Do NOT delete it.