The Partition Sector (boot process)
Results 1 to 6 of 6

Thread: The Partition Sector (boot process)

  1. #1
    Senior Member
    Join Date
    Apr 2002
    Posts
    634

    The Partition Sector (boot process)

    Here are some info about the partition sector of an hard drive which is used during the booting process. Rcgreen has already written an excellent article about the pc boot process here . I will try to add some elements of my knowledge to complete his article.

    During the boot process, the BIOS (for Basic Input/Output System or Basic Integrated/Operating System) launch a script called the Bootstrap. It will search the partition sector which contains all the infos about the partitions into your hard drive and some others interesting things.

    Structure of the Partition sector
    ----------------------------------------
    octet............contain............size
    ----------------------------------------
    00h...............MBR................446
    1BEh.......1st partition...........16
    1CEh.......2nd partition .........16
    1DEh.......3rd partition...........16
    1EEh ......4th partition...........16
    1FEh....identification code.......2
    ----------------------------------------

    Each sector of an hard drive can contain generaly 512 octets of memory and the rule is the same with the Partition sector. It contains in the first 446 octets a partition code most commonly called the MBR (Master Boot Record),it's a script which will read the Partition table, and run the boot sectors of the activated partitions. For example it's in the MBR that you can install LILO in order to select between different OS's on different partitions.

    After the first 446 octets, there is the Partition table. This table contains 4 structures of 16 octets providing infos about partitions. This number of 4 explain why it is not possible to create more of 4 primary partitions on a hdd without using extended partitions (in fact the extended partition contain more than 1 partition but count as only 1 primary partition in the partition table). You need to understand that even if you have not partitioned your hdd, you have 1 partition counted in the partition table.

    Structure of a Partition table
    ----------------------------------------------------------------
    octet.........................contain..............................size
    ----------------------------------------------------------------
    00h...........................state...................................1
    01h.................head of begining...........................1
    02h...........sector & cylinder of begining...............2
    04h....................partition type.............................1
    05h......................head of end.............................1
    06h.............sector & cylinder of end....................2
    08h.....distance with the fist partition sector.......4
    0Ch........number of sectors in the partition.........4
    ----------------------------------------------------------------

    The state can be "00h" if the partition is not activated or "80h" if it is. The info about the head, sectors and cylinders of begining and end of the partition are needed in order to physically find it. We will notice that sectors and cylinders are coded in order to put the cylinder code in only 5 bits and the sectors in 10 bits (1 octet + 2 bits). As a bit can only be a "1" or a "0", this system allow the capability to recognise 2^10 = 1024 sectors. That's why it is not possible to launch boot sectors after the 1024th sector (a real problem with Linux and Windows on the same hdd). The partition type can have differents values like "00h" for a free partition (the partition don't exist) or "04h" for the primary DOS.



    Ok, I think that I have told the more interesting about this subject (in fact, I don't know really more than this )
    If you have coments or if you find an error, don't hesitate to post or to pm me.

    Hoping it will help you...
    Life is boring. Play NetHack... --more--
    Share on Google+

  2. #2
    Kwiep
    Join Date
    Aug 2001
    Posts
    924
    I was searching for those values. Thanks.
    Double Dutch
    Share on Google+

  3. #3
    Banned
    Join Date
    Oct 2001
    Posts
    297
    I have the complete layout by sectors for Floppy, Zip, and Jaz Disks. Great information to have. I will post the pdf on Monday. If you would like a copy via e-mail, please send a PM request, and I will send it to you when I get into work on monday.

    Kiss,

    that is a great tutorial. If I send you my doc, will you add that information in also? No reason in creating another thread for Jaz & Zip.
    Share on Google+

  4. #4
    Senior Member
    Join Date
    Apr 2002
    Posts
    634
    For info:
    No, Fakeboy I plan to update my article only to change possible errors. My article was only for hard drive.
    But you should do your own tutorial about floppy, Jaz & Zip if you have a good documentation.

    Please send me your documentation, it could be interesting. Thanks
    Life is boring. Play NetHack... --more--
    Share on Google+

  5. #5
    Senior Member
    Join Date
    Jun 2004
    Posts
    137
    WELL ITS FINE!!!!

    ILL TRY TO SEARCH FOR MORE DETAILS REGARDING THIS BUT I THINK IT COULD OTHERS
    REGARDING hd
    WELL ANYWAY GOOD JOB BRO.....

    ILL SEE WHAT I CAN ADD.....
    Share on Google+

  6. #6
    Junior Member
    Join Date
    Feb 2006
    Location
    INDIA
    Posts
    5
    nice tutorial
    Share on Google+

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  

 Security News

     Patches

       Security Trends

         How-To

           Buying Guides