Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
/boot/ partition on multi-OS setup
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Other Things Gentoo
View previous topic :: View next topic  
Author Message
augustin
Guru
Guru


Joined: 23 Feb 2015
Posts: 318

PostPosted: Tue Nov 22, 2016 2:22 am    Post subject: /boot/ partition on multi-OS setup Reply with quote

Gentoo is soon to become my primary OS.
I have a new SSD drive that I want to partition to host multiple Linux distributions: Gentoo, my old kubuntu that I need to keep running for a while longer, and maybe leave aside other partitions to install other distribution for testing purposes.
The question is: how to I set up /boot?
It appears that all these distributions will share the same hard drive, so they will share the same MBR which, I believe, can only point to one /boot partition in one of the distributions. Does this mean that the other distributions will not need their own /boot? Or should /boot be installed on a partition of its own and shared between all the distros?
What would the recommended size be for this /boot partition?

Gentoo being the primary OS, I'll use it to configure the MBR and grub.
Back to top
View user's profile Send private message
ct85711
Veteran
Veteran


Joined: 27 Sep 2005
Posts: 1791

PostPosted: Tue Nov 22, 2016 5:14 am    Post subject: Reply with quote

well for me, I would just have the single boot partition and share it for all of the linux distros.

The main thing you will need to do, is make sure grub points to the various linux partitions for their applicable kernel. (the root= parameter will be an important thing to mount the correct linux partition...)

The biggest thing to remember is that unless you copy the compiled modules to the other partitions (though you may encounter strange issues doing this), each linux is going have their own kernel. You also have an option to compile everything into the kernel, but you have plenty of time to play around and comfortable playing around with kernel configurations.

As far as partition size, the easiest way will be use how much you are currently using, multiple it by the number of linux distros, and give a fudge factor of about 20-25% (for future growth). If you also want to have windows boot loader also on it, include that in your calculations. Personally, I like to make sure I don't have to worry about of space on my boot partition, so I usually allocate anywhere between .5-1G (it's overkill, but considering I tend to have 5+ old kernels saved, I won't have to worry about running low on space). So the point I am making is make sure you give yourself plenty of leeway, as it's significantly harder trying to expand the boot partition (commonly tends to be the first partition).
Back to top
View user's profile Send private message
augustin
Guru
Guru


Joined: 23 Feb 2015
Posts: 318

PostPosted: Wed Nov 23, 2016 3:00 am    Post subject: Reply with quote

Thank you very much, ct85711.
That's helpful.
Back to top
View user's profile Send private message
Princess Nell
l33t
l33t


Joined: 15 Apr 2005
Posts: 916

PostPosted: Wed Nov 23, 2016 11:59 pm    Post subject: Reply with quote

Sharing /boot should be fine as long as all OSes are Linux. If you add a different OS into the mix, you'll need to go down the chainloader route, or whatever the equivalent is in grub2. Bear in mind that if you plan to add a different OS later, it may need to live on a primary partition (if you use BIOS, not UEFI).
Back to top
View user's profile Send private message
augustin
Guru
Guru


Joined: 23 Feb 2015
Posts: 318

PostPosted: Thu Nov 24, 2016 12:49 am    Post subject: Reply with quote

Other OS'es are out of the question. I have never tried apple, and haven't used anything windows in 16 years.
This baby is pure GNU/Linux.
:)
Back to top
View user's profile Send private message
augustin
Guru
Guru


Joined: 23 Feb 2015
Posts: 318

PostPosted: Thu Nov 24, 2016 12:54 am    Post subject: Reply with quote

Princess Nell wrote:
Bear in mind that if you plan to add a different OS later, it may need to live on a primary partition (if you use BIOS, not UEFI).

I am not sure I understand what you mean.
This here is a old-ish computer, so there is no UEFI, only plain old BIOS.
I do plan to use GPT to partition the disk, and not use a MBR, though, so there wouldn't be any primary/extended partitions.

http://www.anchor.com.au/blog/2012/10/the-difference-between-booting-mbr-and-gpt-with-grub/
Back to top
View user's profile Send private message
augustin
Guru
Guru


Joined: 23 Feb 2015
Posts: 318

PostPosted: Thu Nov 24, 2016 8:29 pm    Post subject: Reply with quote

I have an additional, very straightforward question:

On a BIOS-GPT system (i.e. no UEFI):
I partition my disk this way:

1) 2MiB with the bios_grub flag
2) 1GiB ext2 for /boot/
3) 30Gib ext4 for / for Gentoo.
4) the rest divided for other distros and for /home/.


My question is concerning the second partition, the ext2 for /boot/.
In gparted, do I need to set the 'boot' flag?
I read conflicting information about it:
https://wiki.gentoo.org/wiki/Handbook:AMD64/Installation/Disks
"Some buggy BIOSes or EFIs configured to boot in BIOS/CSM/legacy mode might also have problems with booting from GPT labeled disks. If that is the case, it might be possible to work around the problem by adding the boot/active flag on the protective MBR partition which has to be done through fdisk with the -t dos option to force it to read the partition table using the MBR format."
...
"When using the UEFI interface to boot the system (instead of BIOS), mark the boot partition as the EFI System Partition. Parted does this automatically when the boot option is set on the partition:"
...
"Type a to toggle the bootable flag on a partition and select 2. After pressing p again, notice that an * is placed in the "Boot" column."

elsewhere I read that the 'boot' flag on an uefi system was for a partition of type fat32 (vsfat).

Basically, I am confused: the 'boot' flag is to be used for BIOS or for EUFI or both?
Should I set it for my ext2 /boot/, or I shouldn't, or it doesn't matter either way?
Back to top
View user's profile Send private message
augustin
Guru
Guru


Joined: 23 Feb 2015
Posts: 318

PostPosted: Fri Nov 25, 2016 10:02 pm    Post subject: Reply with quote

According to the following, the bootable flag ('boot') is not necessary at all.
http://unix.stackexchange.com/questions/37929/difference-between-bootable-and-non-bootable-partitions?noredirect=1
http://unix.stackexchange.com/questions/23560/what-is-the-bootable-flag-option-when-installing-a-distro
http://unix.stackexchange.com/questions/325886/bios-gpt-do-we-need-a-boot-flag
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Other Things Gentoo All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum