[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: partitions - primary vs logical and bootability

On Sat, 10 Nov 2012 16:09:36 -0600
Charles Blair <c-blair@illinois.edu> wrote:

>    I am trying to set up a dual-boot windows 7 / wheezy.
>    The installer shows me 3 primary ntfs partitions,
> presumably for windows7.
>    I have been able to resize to create freespace.
> As I understand it, / must be bootable, which seems
> to mean it must be a primary partition.  However,
> when I do that, the installer shows the remaining
> free space as "unusable," and won't let me create
> logical partitions for swap, /usr, etc.
>    I'm sure I'm overlooking something basic.  Thanks
> for your patient help.

As others have said, up to four primary partitions, OR one extended
partition and up to three primaries.

The difference between them is that only four slots are allocated for
partitions in the table: IBM apparently thought that nobody would ever
need more than four. The 'extended' partition is an entry in the four
slot table pointing to another disc area where more partition table
entries can be placed. There's little agreement on how many are
'enough' these days, and an OS will often permit more on a SCSI drive
than an ATA. You can usually bet on at least ten 'logical' partitions
being available.

There is no practical difference between primary and logical partition
usage *except* that Windows (up to and including XP to my knowledge,
probably later versions also) requires that the first primary partition
it can recognise (i.e. the partition table says it's FAT or NTFS) must
be marked with the 'bootable' flag, and must contain a few critical boot
files. Apart from that, anything can be anywhere, including the Windows
directory which contains the entire OS apart from the boot files.

Linux does not make use of the 'bootable' flag, though Linux
partitioning utilities can set and display it. Linux does not need
anything to be stored on a primary partition.

By the way, one or possibly two of the NTFS partitions will not
normally be used, they are usually a recovery partition (MS hasn't
supplied installation media for many years) and the computer
manufacturer's rescue tools and drivers. Windows itself normally only
uses one partition on consumer OEM computers. If that is indeed the
case, they can be copied off elsewhere (with a note of their partition
table entries) and the space used, and can be copied back to the same
physical disc locations if you ever need to reinstall Windows. Don't
try moving Windows itself (though its partition can usually be shrunk)
because some of the OS knows where it is, on which individual hard
drive, and assumes that if it's not there it's an illegal copy, and
will refuse to run.

Note that the partition table is completely separate from the rest of
the drive. The first thing you ever do when messing with partitions is
to write all the numbers down or print it. Then, if you make a complete
mess of the table, so long as you haven't mounted anything and written
to it, you can often use a rescue disc to rewrite the partition table
exactly as it was, and restore things. Just don't bet irreplaceable
files on that principle, because the one day you are out of luck will
be that day...


Reply to: