LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   Primary partition (https://www.linuxquestions.org/questions/linux-newbie-8/primary-partition-844833/)

Whatif 11-17-2010 09:11 AM

Primary partition
 
Which partitions should be set as primary, /, /home, /tmp, /var, /boot or any other?

Thanks,
Mike

johnsfine 11-17-2010 09:12 AM

It doesn't matter.

Linux doesn't care whether any of its partitions are primary vs. logical.

Whatif 11-17-2010 02:11 PM

Well, I read that the /boot partition must be on a primary partition. Was this true at any point in time?

brianL 11-17-2010 02:29 PM

Quote:

Originally Posted by Whatif (Post 4162221)
Well, I read that the /boot partition must be on a primary partition. Was this true at any point in time?

I don't know, but it's certainly not true now. Some people like to have a separate /boot partition, others (me) don't. I've always only had / and swap, but some prefer / , /home, and swap. Others have even more.

TobiSGD 11-17-2010 02:37 PM

Quote:

Originally Posted by Whatif (Post 4162221)
Well, I read that the /boot partition must be on a primary partition. Was this true at any point in time?

There was a time when some bootloaders had problems when the /boot-partition was at a cylinder number greater than 1024, but these days are long gone.

hilyard 11-17-2010 04:50 PM

Sorry, brianL, but take a look at KahelOS Manual, page 10

1. Auto-Prepare. This option will erase the ENTIRE hard drive and skips options 2 and 3 because autoprepare will already partition your hard drive (Option 2) and set mounting points for your filesystem (Option 3).
(a) Partitioning /boot. In Kahel OS, the default /boot partition is 32MB. You can enter other values then select OK to save it.

Kahel is based on another modern Linux distro.

brianL 11-17-2010 05:09 PM

Yeah, Arch (I think) recommends a separate /boot partition too in their installation manual, but a lot of distros don't bother.

markush 11-17-2010 05:22 PM

Quote:

Originally Posted by brianL (Post 4162376)
Yeah, Arch (I think) recommends a separate /boot partition too in their installation manual, but a lot of distros don't bother.

Well, I'm running Arch without a separate bootpartition. It grumbles while the installationprocess but there is an option to ignore the grumble. I've never had problems without a separate bootpatition, with every distribution.

Markus

brianL 11-17-2010 05:41 PM

Like I said before, it's optional, not necessary.

Tinkster 11-17-2010 05:44 PM

Quote:

Originally Posted by hilyard (Post 4162362)
Sorry, brianL, but take a look at KahelOS Manual, page 10

1. Auto-Prepare. This option will erase the ENTIRE hard drive and skips options 2 and 3 because autoprepare will already partition your hard drive (Option 2) and set mounting points for your filesystem (Option 3).
(a) Partitioning /boot. In Kahel OS, the default /boot partition is 32MB. You can enter other values then select OK to save it.

Kahel is based on another modern Linux distro.

Ummmm ... and?



Cheers,
Tink

syg00 11-17-2010 05:53 PM

/boot is optional until you delete the partition that has the boot-loader code. Then you decide it's kinda mandatory.
Lots of people seem to do it (the former) judging by threads here.

FWIW I've always allocated one at the start of a disk since the bad old days when the BIOS (note BIOS, not bootloader) had the 1024 cylinder problem. Still do.

brianL 11-17-2010 06:01 PM

Yeah, I admit it might be useful under certain circumstances, but it's not essential. Like having a separate /home partition may be useful, but not necessary.

TobiSGD 11-17-2010 06:06 PM

Quote:

Originally Posted by syg00 (Post 4162414)
since the bad old days when the BIOS (note BIOS, not bootloader) had the 1024 cylinder problem.

I thought it was the bootloader, not the BIOS. Googled now after it, and we are both right, there were issues wit the BIOS and LILO back in the days, both had the 1024 cylinder problem.

GazL 11-17-2010 06:19 PM

I think most distros recommend a separate /boot in a primary partition because it allows for an encrypted rootfs, or rootfs on LVM or RAID setups, and is organisationally just a tidy way to do things.

If you install the grub/lilo boot-manager code on the Master Boot Record (MBR), then I don't believe you need a primary at all, but if like me you prefer to leave the MBR as it is and put the Linux bootloader on a Partition Boot Record (PBR), then you'll need one primary partition which you can mark as bootable in the partition table. The standard bootcode in the MBR will find the partition that is marked as bootable and load the Linux bootloader code from that partition's PBR. It doesn't matter which filesystem is on that partition. From an organisational standpoint / or /boot are the most sensible choices, but it could just as easily hold /home (it just doesn't make a lot of sense to do so).


I fall into the "keep the MBR standard, lilo or grub on a primary partition holding /boot, and everything else in an LVM partition" camp.


P.S. I believe that OpenBSD's bootloader still has the 1023 cylinder limitation on it's loader code, so it probably still needs to be placed on the beginning of a disk. I've no idea about where Windows needs to be.

frieza 11-17-2010 06:24 PM

if you had /boot and /lib/modules on separate partitions then you could share kernels between multiple distributions with separate / partitions, other then that /boot is only useful on older machines that have the 1024 cylinder limit
http://tldp.org/HOWTO/Large-Disk-HOWTO-4.html should explain it


All times are GMT -5. The time now is 06:16 PM.