Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 28 Dec 2009 21:04:57 +0800
From:      Fbsd1 <fbsd1@a1poweruser.com>
To:        Jerry McAllister <jerrymc@msu.edu>
Cc:        Polytropon <freebsd@edvax.de>, FreeBSD Questions <freebsd-questions@freebsd.org>
Subject:   re-write is this booting info correct?
Message-ID:  <4B38ACF9.2050705@a1poweruser.com>
In-Reply-To: <20091217151140.GA40367@gizmo.acns.msu.edu>
References:  <4B296E66.6030405@a1poweruser.com>	<20091217064959.e62bfdbb.freebsd@edvax.de> <20091217151140.GA40367@gizmo.acns.msu.edu>

next in thread | previous in thread | raw e-mail | index | archive | help


How is this rewrite correct?

Users with Microsoft/Windows knowledge of how a hard drive is configured 
may have a terminology issue with FreeBSD. Microsoft/Windows and FreeBSD 
use the word partition to mean different (but related) things.

The Microsoft/Windows fdisk program is used to allocate partitions on 
the hard drive. This program allocated two types of partitions “primary 
dos partition” and “extended dos partition”.
A single “primary dos partition” occupying all the space on the hard 
drive would be assigned drive letter C. You can also sub-divide the hard 
drive into multiple “primary dos partition” each one being assigned a 
drive letter C, D, E, F,
An alternate method is to allocate an “extended dos partition” and then 
sub-divide it into logical dos drives lettered C, D, E, F. One of these 
“primary dos partitions” or one of the logical dos drives in the 
“extended dos partition” must be set as the active partition to boot 
from. In a multiple partition allocation only one partition can be 
marked as bootable at one time. Typically legacy Microsoft/Windows 
Win3.1, Win95, Win98, WinMe, and Win2000 defaulted to a single “primary 
dos partition”. Starting with XP, PC manufactures started to provide 
support for their PC’s operating system by having a second  “primary dos 
partition” where the original factory version of the system was hidden 
and used to restore the C drive back to the factory version when 
corrupted by a virus. Microsoft/Windows provides no native method of 
selecting which partition to boot from in a multiple partition allocation.

FreeBSD’s fdisk program allocates disk space into slices. A FreeBSD 
slice is the same thing as a Microsoft/Windows  “primary dos partition”. 
FreeBSD has nothing akin to an “extended dos partition”. The 
Microsoft/Windows partition and the FreeBSD slice is where the operating 
system software is installed. Microsoft/Windows operating system creates 
default folders that share the space in the partition.  The FreeBSD 
‘disk label’ program is used to sub-divide the slice into smaller chunks 
called partitions. In a standard install of FreeBSD, these partitions 
are the default directory names used by the operating system.

The motherboard standard which was created in the days before windows 
desktop were even though of yet and at which time Microsoft DOS (disk 
operating system) was the only thing available. This legacy standard has 
continued un-updated to this current time and contributes to the 
limitations imposed on booting, disk layout and selection of which 
allocation on the hard disk to boot from.

The motherboard BIOS ROM chip at power up inquires each device 
(floppies, cdrom, hard drive, usb memory stick) you selected in the BIOS 
menu to boot from.

The hard drive has a MBR (Master Boot Record) a (512 byte block) located 
in sector-0 of the first physical track on the hard drive. This MBR 
contains bootstrap code and the disk partition table created by the 
fdisk program. The BIOS boot code reads the MBR code and disk partition 
table into memory and then transfers control to it. This MBR code is 
responsible for parsing the partition table and finding the bootable 
slice/partition that is marked 'active'.  The MBR code then sets up the 
disk-address-offset information for the bootable slice/partition, and 
reads 'relative sector zero' from that slice/partition, and transfers 
control to that one-sector block of code that contains the unique 
operating system code to load it into memory.

This hard drive 512-byte MBR is where all the limitations are. Do to 
it’s size the MBR partition table is limited to 4 entries. This means no 
matter how large your hard drive is (20MG or 200GB) you can only 
sub-divide it into a maximum 4 slices/partitions.

The default MBR code written by the Microsoft/Windows fdisk program is 
hard coded to boot the C drive. The FreeBSD fdisk program has option to 
write a simple boot menu program to the MBR.
There are MBR boot menu programs in the FreeBSD ports collection that 
you can load into the MBR on the first physical cabled hard drive to 
scan for other bootable primary-partitions/slices on this hard drive and 
any other hard drives cabled to the PC. It displays a menu giving you 
the option to choose which one you want to boot from. This gives you the 
ability to have more that one operating system installed on your PC at 
one time.









Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?4B38ACF9.2050705>