Strange booting problem

Rick Stevens ricks at alldigital.com
Fri Jun 26 23:46:37 UTC 2015


On 06/26/2015 04:29 PM, Rick Stevens wrote:
> On 06/26/2015 04:05 PM, jd1008 wrote:
>>
>>
>> On 06/26/2015 04:55 PM, Gordon Messmer wrote:
>>> On 06/26/2015 02:51 PM, jd1008 wrote:
>>>> Just wondering about the bytes in the first sector which
>>>> you thought might be boot code that is confusing BIOS
>>>> to think that my usb drive is bootable.
>>>> The bytes you already saw are obviously not boot code.
>>>
>>> What is obvious to you is not obvious to the CPU, which simply
>>> executes instructions.  Everything in bytes is 0-446 is boot code,
>>> whether it does anything useful or not.
>> Fine! No argument there.
>> Where do device (or partition) labels reside? In the partitions?
>
> fdisk- (dos-) style partition tables do not have partition labels. GPT
> partitions do. They are 72 bytes long, starting at offset 56 in the
> partition's entry in the partition table.
>
> The location of the partition table is given in an 8-byte value
> starting at offset 72 in the GPT header. Generally, they start at the
> second LBA (LBA1) on the disk and are 128 bytes long.

My bad, the table starts in the third LBA (LBA2). LBA0 is the MBR,
LBA1 is the GPT header, and the partition table starts at LBA2. As an
aside, EFI specifies that there will be at least 128 partition entries,
so this will occupy at least 16K (16,384) bytes.

> Filesystem labels (regardless of DPT or GPT partitioning) are located
> in the filesystem's superblock(s). They are 16 bytes long starting at
> offset 120 in each copy of the superblock.
----------------------------------------------------------------------
- Rick Stevens, Systems Engineer, AllDigital    ricks at alldigital.com -
- AIM/Skype: therps2        ICQ: 226437340           Yahoo: origrps2 -
-                                                                    -
-          When all else fails, try reading the instructions.        -
----------------------------------------------------------------------


More information about the users mailing list