Dual boot using UEFI boot mode
I personally need both Linux and FreeBSD to be available to me. Linux for things like Udemy.com for training, and FreeBSD for working on my orange pi zero setups. Leaves me in an intersting position. I don't really like running either in a vm on my laptop, prefer native. Don't need both running at the same time. So how did I solve this?
EUFI allows you to do what we used to do in grub, or using System Commander, etc, and have multiple boot options. Only thing is (on my thinkpad) hit the F12 key if you are not wanting the default booted. I usually have my Debian as primary, so I have to hit F12 and choose FreeBSD from the menu if I want it to boot FreeBSD.
No configs or archaic commands to manage. The bios of your machine will deal with it for you. Below is the steps I took on my ThinkPad.
- turned on UEFI BOOT ONLY in the bios. See pic below. installed Debian as normal. I had previously installed Debian to use the entire disk, which if you haven't already, then save some drive space for FreeBSD.
- Installed Freebsd. As said in step three I did not leave room for FreeBSD when I installed Debian. So here are the steps to clear room for FreeBSD.
- Booted to a Linux Mint usb thumb drive. Mint has excellent tools on their live usb.
- ran gparted and used it to reduce the size of the main drive to allow 400 GB or so for FreeBSD leaving about 600 GB for Debian. You decide your needs. FreeBSD Only needs at the MOST 30 GB to run with everything in the world installed.
- Booted to the FreeBSD install program from the FreeBSD USB drive I have.
- Did a standard install with the one step was to manually partition the drive. Once you do that you click on the drive with the free space and then put for it to create a new partion. Change the mount point from blank to be root by putting / in the field. Then click ok and tell it to proceed.
- IF it asks you about adding a menu item to the EUFI boot menu, say yes to that.
- Reboot and it should automagically boot FreeBSD because it puts FreeBSD as the first entry in the boot menu. Once you are sure your freebsd is booting, reboot your machine and go into the bios settings.
- Configure your UEFI boot menu to boot what you want to boot normally. I have mine set to Debian and I hit F12 at boot time to pick FreeBSD from the menu when
I want to run Fr..eeBSD.
So with this you can pretty easily dual boot FreeBSD with a Linux Distro on your laptop/computer.
This method would probably also work for other distros and BSDs also. ONLY tried it with Debian and FreeBSD 13.