Primary vs. Logical
On my notebook I have a ~ 115GB HD, I resized the NTFS partition to get ready for Slackware 11.0. NTFS is now 54.7GB, made a 26.5GB FAT32 partition for sharing files between Linux and XP, made a 100MB ext2 partiton for boot, 22GB ext3 for home, though I will probably change that to reiser or jfs, but thats far as I can get, I get limited to only 4 primary partitons... Why the limit to only 4? I originally wanted this kind of setup....
NTFS Primary 54.7GB FAT32 Primary 26.5GB ext2 boot Primary 100MB home Primary 22GB / ReiserPrimary 8.97GB I thought I heard that you could have a much higher number of primary partition, but apparantly not. So should I make / as a logical partition then? |
You can only have 4 primary partitions I think. You can make 1 primary NTFS for windows, then make an extended partition of the remaining space and create as many logical drives in that as you like. So it will look like:
Code:
[Primary][-------------Extended-------------] |
You can have 4 primary maximum. If you want more than 4
partitions, you can make 1 (as dive said) or up to 3 as primary, then the rest must be logical partitions in the extended partition. Windows is going to want to have it's boot partition in the primaries -- Linux doesn't care -- it's just happy to be selected and will run anywhere. :D |
Dive's already correct. This is only for a bit of more info.
Code:
[HEADER][Primary][------------------Extended-------------------] |
You can only have 4 primary partitions. If you need MORE partitions, you can have up to 3 primary and the last extended containing logical partitions.
So, you could have 1-3 be primary and 4 be extended while containing more logical partitions. -=[EDIT]=- Duh - you beat me to it. |
I know this has already been covered but I just thought I'd share the way I've partitioned my HD so you can perhaps put it into perspective....
Code:
[----------------------------HD-------------------------------] hda1 - NTFS 10GB /mnt/windows for Windows XP hda2 - ext2 60MB /boot hda3 - ext3 15GB / for Main Linux distr hda5 - swap 1GB hda6 - ext3 25GB /home hda7 - fat32 5GB /mnt/shared for sharing between Linux and XP, shows up as D:\ in XP hda8 - ext3 4GB /mnt/extra for testing distros, or re-mastering knoppix etc, anything else basically. So as you can see you can pretty much partition your HD anyway you want as far as Linux is concerned. |
That's an excellent illustration.
|
yes and as you can see there's no hda4. it's simply the extended partition header. btw it's not just 1 sector perhaps it's 1 head.
|
Just to be more confusing....
When hard drives became available for the PC one could only create 4 total partitions. As hard drives started increasing in capacity this became a big limitation. The extended partition was developed to overcome this limitation but still retain backwards compatabilty. The original 4 partitions are now known as primary. An IDE drive can be subdivided into 64 partitions, 4 primary (1 designated as extended) and 60 logical partitions. A SCSI can be subdivided into 16 partitions (AFAIK this is a linux limitation). BTW Windows has a limitation of 26 total partitions i.e. A-Z. Any primary partition can be designated as an extended partition. konsolebox, I believe you are refering to the boot sector as a header. Each primary partition has a boot sector. The extended partition has an extended master boot record which is just a pointer to the first logical. Probably too much information for the OP to comprehend at this time. |
Hi,
Quote:
If you do a fdisk -l on your system you will find something like this; Code:
Disk /dev/hda: 40.0 GB, 40007761920 bytes Quote:
My personal taste is too create my swap if needed as device /dev/hda2 as seen in the below fstab example. Reasoning is the device access times for primary vs extended. You could create the swap on an extended but there would be propagation. A fstab example; Code:
/dev/hda2 swap swap defaults 0 0 edit: correct spelling missed by LQ spell check. |
Quote:
About the illustration I posted above I think there's still nothing to change. Thanks for the correction. |
A bit of advice for keeping windows happy on the same HD as Linux:
Make the first and last logical partitions either NTFS or FAT. Otherwise Windows may have trouble reading the partition table. This is covered in several MS Knowledge Base advisories. The easiest way to accomplish this is to create all your partitons as windows-type, then afterwards change the ones you want to be Linux using Linux fdisk, but without destroying them or changing the size. About that tutorial -I never in my life saw so much disinformation in so little space. It may help you to understand in a round-about way, but that guy needs to read up before writing anymore... |
All times are GMT -5. The time now is 03:38 PM. |