Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

GUID@linux.os

9 views
Skip to first unread message

Johannes Koehler

unread,
Mar 11, 2022, 7:15:55 AM3/11/22
to
Much values!

my first news posting within your group. Searching for help
regarding linux and gnu partition tables:

Ordinal system usage principles... i am used to at ∀, means: menu driving
with answer from 1 to x without floating point decisions... A bit of
irony. :)

Based on that reason... I want to use cmdline bins like sgdisk and sfdisk in
the future, to work on block device ordering and to build the space to work
with linux.

But... I went -fast- into flowing ground. I.e., I like to create more then
one gpt partition table at one device (hybrid mbr?).

The idea came into being... It was not possible to create more then three
partitions into a newly created gpt header. The docs telling about up
to 128 partitions. Menudriving@gdisk opens the way for this big amount
of partion table entrys, but sgdisk not. I also wiped the mbr
and gpt data before starting on with creating new partions using sgdisk
with GUID tables.

Reading the manpages, and web resources mentioned in this gnu manpages,
was not sufficient to understand the based numbering principle,
and to work on knowledge without the wider sense of possible meanings.
I.e to understand hybrid partitions.

Now and maybe... Somebody can give me a hint to some more documentation,
to extend the docs from the developer "rodsbooks".

thx and sincerely
- kefko




David W. Hodgins

unread,
Mar 11, 2022, 2:06:23 PM3/11/22
to
On Fri, 11 Mar 2022 07:15:54 -0500, Johannes Koehler <j...@johannes-koehler.de> wrote:
> But... I went -fast- into flowing ground. I.e., I like to create more then
> one gpt partition table at one device (hybrid mbr?).

Would you try to create more than one master boot record on an mbr disk? Don't
try to create more than one gpt partition table per device.

When using gpt, there may optionally be an mbr. There are two types. Protective
and hybrid.

A protective mbr has one partition defined that covers the entire device. It's
purpose is ensure old partitioning software will think the entire drive is in
use, to help the user accidentally messing things up.

A hybrid mbr allows booting on old bios firmware systems that do not recognize
gpt partition tables. It's used to store the bootloader code such as stage 1
of grub.

Up-to-date versions of fdisk, sfdisk, cfdisk, etc. all work ok with gpt. Don't
use old partitioning software that doesn't handle gpt.

Other then knowing that gpt can handle a lot more partitions on a device than
mbr can, don't worry about partition numbers anymore. With gpt, there's no such
thing as extended or logical partitions. All partitions are primary partitions.

In most cases, such as during boot the partitions will be identified by it's UUID
(Universally unique identifier).

Be extremely careful when cloning disks to change the uuid on the new copy before
rebooting with both disks attached. Having non-unique UUIDs in the same system
makes it unpredictable which partition will be selected.

Since remembering a uuid is hard, in most cases a label may be used. Create a
label for each partition, again making sure it's unique, and use that instead
of the uuid to keep track of which partition is for what.

> The idea came into being... It was not possible to create more then three
> partitions into a newly created gpt header. The docs telling about up
> to 128 partitions. Menudriving@gdisk opens the way for this big amount
> of partion table entrys, but sgdisk not. I also wiped the mbr
> and gpt data before starting on with creating new partions using sgdisk
> with GUID tables.

That doesn't make sense. How old is the software you're using?

> Reading the manpages, and web resources mentioned in this gnu manpages,
> was not sufficient to understand the based numbering principle,
> and to work on knowledge without the wider sense of possible meanings.
> I.e to understand hybrid partitions.

Hope the above helps. Feel free to ask if anything isn't clear.

Regards, Dave Hodgins

Johannes Koehler

unread,
Mar 13, 2022, 5:01:24 AM3/13/22
to
On 2022-03-11, David W. Hodgins <dwho...@nomail.afraid.org> wrote:
>> But... I went -fast- into flowing ground. I.e., I like to create more then
>> one gpt partition table at one device (hybrid mbr?).
>
> Would you try to create more than one master boot record on an mbr disk? Don't
> try to create more than one gpt partition table per device.

Would uefi handle more then one gpt table while booting? E.g. booting
diffrent efi grub bootloader partitions at one device? Thought about using
hybrid mbr records with this more gpt tables...

>> The idea came into being... It was not possible to create more then three
>> [...]
>
> That doesn't make sense. How old is the software you're using?

Sry... Made a mistake on using sgdisk parameters.

> Hope the above helps. Feel free to ask if anything isn't clear.

When working with parted,sgdisk,gdisk,partx and wipefs there came
some questions into been:

Wipefs... Showing more then one label for an whole device with one
gpt tabled partition. (E.g. GPT and PBMR labels with an sector offset)
The sense would be, wipefs is showing gpt data instead of filesystem data
like mentioned in the manpages?

Sector alignment... When i am using SI instead of EIC alignment
then it would mind to align it to e.g. 2000 instead of 2048bytes?
Neither of the tools, provided by gnu and apple, let me change the
value with an result in the mode settings?

Sector size... I distinguiѕh between sector alignment value
and physical/logical sector size. Is there a possibility to set the
logical sector size? Because, btrfs takes raw devices, also. When
i create a software raid with btrfs, it should have the possiblity
to align the sectors on the fly. Then logical=physical sector size
should fasten the device I/O?

Thx and much values!
- kefko

David W. Hodgins

unread,
Mar 13, 2022, 10:47:42 AM3/13/22
to
On Sun, 13 Mar 2022 05:01:23 -0400, Johannes Koehler <j...@johannes-koehler.de> wrote:

> On 2022-03-11, David W. Hodgins <dwho...@nomail.afraid.org> wrote:
>>> But... I went -fast- into flowing ground. I.e., I like to create more then
>>> one gpt partition table at one device (hybrid mbr?).
>>
>> Would you try to create more than one master boot record on an mbr disk? Don't
>> try to create more than one gpt partition table per device.
>
> Would uefi handle more then one gpt table while booting? E.g. booting
> diffrent efi grub bootloader partitions at one device? Thought about using
> hybrid mbr records with this more gpt tables...

First get it out of your mind that gpt is only for uefi.
Bios firmware works with gpt partitioned drives or mbr partitioned drives.
UEFI firmware works with gpt partitioned drives or mbr partitioned drives.
There are some exceptions due to faulty firmware and ancient bios firmware, but
both types of firmware are supposed to work with either partitioning schemes.

A gpt partitioned hard drive has one, and only one partition table header
https://en.wikipedia.org/wiki/GUID_Partition_Table#Partition_table_header_(LBA_1)
with one backup copy of that header. The table header is followed by the partition
table entries.

>>> The idea came into being... It was not possible to create more then three
>>> [...]
>>
>> That doesn't make sense. How old is the software you're using?
>
> Sry... Made a mistake on using sgdisk parameters.
>
>> Hope the above helps. Feel free to ask if anything isn't clear.
>
> When working with parted,sgdisk,gdisk,partx and wipefs there came
> some questions into been:
>
> Wipefs... Showing more then one label for an whole device with one
> gpt tabled partition. (E.g. GPT and PBMR labels with an sector offset)
> The sense would be, wipefs is showing gpt data instead of filesystem data
> like mentioned in the manpages?

With an mbr partitioned hard drives, labels only apply to file systems, and
are stored inside of the file system by the file system formatting software.
There's also a 32-bit disk signature in the mbr.

With gpt partitions, in addition to the file system label, the partition table
entries also have a "Partition Name". That name is assigned to the partition,
and is not changed by formatting the file system inside of the partition which
still have their own labels.

> Sector alignment... When i am using SI instead of EIC alignment
> then it would mind to align it to e.g. 2000 instead of 2048bytes?
> Neither of the tools, provided by gnu and apple, let me change the
> value with an result in the mode settings?

Hard drive marketers use 1000 as the base, but all computer partitioning software
and the drive firmware is based on 1024.

Most partitioning software now defaults to aligning things on 1 MiB boundaries.
That's 1048576 bytes, 2048 sectors for 512 byte sectors, or 256 sectors for 4096
byte sectors.

It works well with the physical write sizes used by hard drives, ssd drives, and
sd flash drives. Those write sizes vary between 512 bytes, 4096 bytes, 8192 bytes,
and possibly larger sizes.
1 Mib = 2048 x 512 bytes
1 Mib = 4096 x 256
1 Mib = 8192 x 128

For hard drives, logical sector size is used for addressing, but all i/o is done
using physical sectors. For flash based storage (ssd drives and sd cards), i/o is
done using pages (similar to logical sectors), but the i/o is done based on the
page erase size (similar to physical sectors).

> Sector size... I distinguiѕh between sector alignment value
> and physical/logical sector size. Is there a possibility to set the
> logical sector size? Because, btrfs takes raw devices, also. When
> i create a software raid with btrfs, it should have the possiblity
> to align the sectors on the fly. Then logical=physical sector size
> should fasten the device I/O?

The physical and logical sector size for a given device are controlled by the
firmware on that device. Very old partitioning software assumed 512 byte sectors,
and track alignment, but all current software uses 1MB alignment.

Don't use ancient software and let it do it's job without overriding things
without very good reason, and understanding of the underlying technology.

Regards, Dave Hodgins

l0ft_908

unread,
Aug 29, 2022, 7:48:02 PM8/29/22
to
Johannes Koehler wrote:
> Much values!
>
> my first news posting within your group. Searching for help
> regarding linux and gnu partition tables:
>
> Ordinal system usage principles... i am used to at ∀, means: menu driving
> with answer from 1 to x without floating point decisions... A bit of
> irony. :)
>
> Based on that reason... I want to use cmdline bins like sgdisk and sfdisk in
> the future, to work on block device ordering and to build the space to work
> with linux.
>
> But... I went -fast- into flowing ground. I.e., I like to create more then
> one gpt partition table at one device (hybrid mbr?).
>
> The idea came into being... It was not possible to create more then three
> partitions into a newly created gpt header. The docs telling about up
> to 128 partitions. Menudriving@gdisk opens the way for this big amount
> of partion table entrys, but sgdisk not. I also wiped the mbr
> and gpt data before starting on with creating new partions using sgdisk
> with GUID tables.
>

check check, can't get alt.b.test - no internet from centerylink - just
cecking...
0 new messages