Grub2 Configuration (Dual boot linux + FreeBSD is it possible?)

Hi,

I would like to have FreeBSD. But when I try to install 8.2 Grub2 stops working as I described here http://forums.freebsd.org/showthread.php?t=26774. I know that there is a section for FreeBSD boot loader http://www.freebsd.org/doc/en_US.ISO8859-1/books/handbook/boot-blocks.html#BOOT-BOOT0-EXAMPLE but it's not clear to me how I can configure it to use FreeBSD, Linux and Windows. I tried to use 9Beta3 but it tries to create 3 partitions on my disk where there are already two partition (linux-swap and ext4). So with 5 primary partitions it can't work in any way. How I can install FreeBSD then? Is this possible?
 
marcinnn said:
Hi,

I would like to have FreeBSD. But when I try to install 8.2 Grub2 stops working as I described here http://forums.freebsd.org/showthread.php?t=26774. I know that there is a section for FreeBSD boot loader http://www.freebsd.org/doc/en_US.ISO8859-1/books/handbook/boot-blocks.html#BOOT-BOOT0-EXAMPLE but it's not clear to me how I can configure it to use FreeBSD, Linux and Windows.

The FreeBSD boot0 multi-boot loader is so barebones there is no configuration. It presents a list of what to boot based on what it finds on the disk. But if you've already got Grub, use that. All you have to do is figure out how to set Grub. There should be people here who use it, and searching on that, or Grub2, should be helpful.

I tried to use 9Beta3 but it tries to create 3 partitions on my disk where there are already two partition (linux-swap and ext4). So with 5 primary partitions it can't work in any way. How I can install FreeBSD then? Is this possible?

The three partitions that FreeBSD wants to create are GPT partitions. GPT doesn't have the limit of four. But since you already have an MBR setup, you're stuck with four. So back up the entire drive. Install FreeBSD in the fourth partition (8.2 or 9, but it will require manual selection of some entries). Then configure Grub to boot from it.
 
OK. So on disk with linux swap and ext4 with gpt partition table I installed FreeBSD 9 with it's default 3 partitions.

I tried to boot it with Grub2 and I tried many different options:
Code:
menuentry "freebsd 9" {
       insmod part_gpt
	set root=(hd1,3) #I tried also (hd1,4), (hd1,5), (/dev/sdb,3), (/dev/sdb,4), (/dev/sdb,5), (/dev/sdb,gpt3), (/dev/sdb,gpt4), (/dev/sdb,gpt5)

       chainloader +1
}

but it still doesn't work.

So how I should have configured Grub?
 
Back
Top