Solved installing freebsd 11.2 on laptop with uefi.

I have a msi laptop ge72 7r that I tried to install freebsd on. I turned off secure boot. The laptop have a 256gb ssd drive and a 1tb harddrive. I get the installation to boot from the mem stick and install a guid partition with a gpt, / , and swap partition on the entire disk. The installation seems to go correctly but when I reboot I cant get the harddrive to boot with freebsd. Ive tried installing it on both the 256 and 1tb harddrives but that doesnt help. thank you for any help.
 
Make sure you're using the UEFI version of the FreeBSD installation image. Also, you might try a different partitioning scheme if the laptop is older. Try MBR or BSD instead of GPT.
 
I've installed first FreeBSD. I didn't touch the partition till I can get a stable OS.
The second I did was install whichever the OS you want to.
The third was edit grub.cfg and add FreeBSD to my GRUB since I have no options in the last for installing a GRUB.
 
This is kind of vague so I will guess you see some stuff on screen?

Edit /boot/loader.conf and see if it will run with the old sc console.
/boot/loader.conf
kern.vty=sc

There are also some other video settings you could try if sc doesn't fix anything.

You can add these settings by booting off the USB Memstick, in LiveCD mode.
Then mount the install mount /dev/da0p3 /mnt and edit/create /mnt/boot/loader.conf


the screen blinks no media present.
 
Make sure you're using the UEFI version of the FreeBSD installation image. Also, you might try a different partitioning scheme if the laptop is older. Try MBR or BSD instead of GPT.

the documentation says version 10 and above has uefi built into the image.
 
It does. Sometimes I wish it didn't.

Sound like it could be a BIOS setting.

Do you see any CSM settings in the BIOS?
 
Since this is a disk problem I would experiment with Legacy Only for some of the CSM options.

Another trick I use to try and force a legacy install..
In the BIOS the USB memstick can be detected as either PMAP USB or UEFI USB. Go to 'Hard Disk Priorities' and disable the UEFI USB and move PMAP USB to top. try booting that way.
Some real picky boards you must do the above but on the 'Save and Exit' screen of the BIOS. It has a boot override at bottom left.
Pick PMAP here and hit enter, after setting PMAP as the first booting drive disk drive.

The real way to tell you have an Legacy Install is the color. The ncurses background color of the FreeBSD installer is dark blue.
On a UEFI install they are a light blue. Do you remember which you saw?
You can use GPT on a legacy Install too so that really don't help determining..
 
i dd'd a usb drive with 11.2 and booted it. Now it isnt running the installer but booting a system. And it has the same password I picked when I installed freebsd on the computer in the first place. but if I try to book without the usb in it wont work. I am confused.
 
20180726_035217.jpg
 
Even on modern hardware UEFI is sometimes buggy, so it's possible FreeBSD won't boot in UEFI mode.

On the other hand, you have to get a bit familiar with BIOS/UEFI setting, selecting the right boot device and enable/disable CSM
according to the bootcode on your disk.
Note: every BIOS/UEFI is different. CSM has to be enabled and it has to control both types of boot devices, UEFI and legacy.

As Phishfry said, your trying to boot EFI bootcode (shows from your photo) but that might be buggy on your laptop or
you not booting the right device. Check your /etc/fstab file. It should contain a line like:
Code:
/dev/ada0p2        /        ufs        rw        1        1
If it says ada1p2, because you have two drives, that could be the cause, too. (but FreeBSD would boot into the Beasty menu before failing)

You have to either enable UEFI booting from the BIOS/UEFI or you simply can't boot in UEFI mode because it's buggy.

As a last resort, I'd try to install legacy bootcode and get rid of the /EFI partition on your disk and see if then boots in legacy mode.

You said you have a SSD and a hard disk in that laptop, though only one drive shown up (~750GB size).
I simply assume now that this is your SSD where you wnat to run FreeBSD from.
(if you fiddled with your drives and /dev/ada0p1 is not your SSD as on the photo you might screw up)

Ok, let's remove the EFI bootcode, install a legacy boot partition and a MBR.
Boot into the FreeBSD installer and select "live cd", login as root with no password and run the following commands.
Code:
# gpart delete -i1 ada0

# gpart add -t freebsd-boot -s 512K ada0

# gpart bootcode -b /boot/pmbr -p /boot/gptboot -i1 ada0

If you run gpart show ada0 you'll see that you have a /freebsd-boot partition and the /EFI partition is gone.
Reboot and see... remember you may still have to switch to boot in legacy (CSM enabled) mode. Check your BIOS/UEFI settings.
 
Now it isnt running the installer but booting a system. And it has the same password I picked when I installed freebsd on the computer in the first place. but if I try to book without the usb in it wont work. I am confused.

I have a host at home with just one disk and three partitions on it.

The first partitions already came with it and have Windows 10 installed on them (I didn't get rid of them because sometimes I have to test stuff on Windows and I paid for that license, wanting it or not, when I bought the hardware).

I also have a partition with FreeBSD and another one with Slackware Linux.

All three of them are booted from /EFI and with no help from any boot manager.

I just press F12 when Dell BIOS is at the appropriate screen and choose the right EFI loader to fire up.

Works like a charm.
 
Even on modern hardware UEFI is sometimes buggy, so it's possible FreeBSD won't boot in UEFI mode.

On the other hand, you have to get a bit familiar with BIOS/UEFI setting, selecting the right boot device and enable/disable CSM
according to the bootcode on your disk.
Note: every BIOS/UEFI is different. CSM has to be enabled and it has to control both types of boot devices, UEFI and legacy.

As Phishfry said, your trying to boot EFI bootcode (shows from your photo) but that might be buggy on your laptop or
you not booting the right device. Check your /etc/fstab file. It should contain a line like:
Code:
/dev/ada0p2        /        ufs        rw        1        1
If it says ada1p2, because you have two drives, that could be the cause, too. (but FreeBSD would boot into the Beasty menu before failing)

You have to either enable UEFI booting from the BIOS/UEFI or you simply can't boot in UEFI mode because it's buggy.

As a last resort, I'd try to install legacy bootcode and get rid of the /EFI partition on your disk and see if then boots in legacy mode.

You said you have a SSD and a hard disk in that laptop, though only one drive shown up (~750GB size).
I simply assume now that this is your SSD where you wnat to run FreeBSD from.
(if you fiddled with your drives and /dev/ada0p1 is not your SSD as on the photo you might screw up)

Ok, let's remove the EFI bootcode, install a legacy boot partition and a MBR.
Boot into the FreeBSD installer and select "live cd", login as root with no password and run the following commands.
Code:
# gpart delete -i1 ada0

# gpart add -t freebsd-boot -s 512K ada0

# gpart bootcode -b /boot/pmbr -p /boot/gptboot -i1 ada0

If you run gpart show ada0 you'll see that you have a /freebsd-boot partition and the /EFI partition is gone.
Reboot and see... remember you may still have to switch to boot in legacy (CSM enabled) mode. Check your BIOS/UEFI settings.

thanks it worked but one thing that bugs me is that the font is huge now. When I was booting off the usb drive the font was small and resolution was great. why would it change? vidcontrol -i mode doesnt list and modes.
 
Nice it worked :)
Booting in UEFI mode makes the console driver switch the console to high resolution.
If you load the right kms video driver the console will switch automatically to high resolution as well.
(That means that you'll the the Beasty menu in good old 80x25 mode, and then during the booting process, when the driver loads it will switch)

I have never used any Nvidia card so I can't help with that, search the forum, there are several threads on that topic.
You'll need a kms driver anyway in case you want to run Xorg, without you won't get hardware acceleration.
 
Nice it worked :)
Booting in UEFI mode makes the console driver switch the console to high resolution.
If you load the right kms video driver the console will switch automatically to high resolution as well.
(That means that you'll the the Beasty menu in good old 80x25 mode, and then during the booting process, when the driver loads it will switch)

I have never used any Nvidia card so I can't help with that, search the forum, there are several threads on that topic.
You'll need a kms driver anyway in case you want to run Xorg, without you won't get hardware acceleration.

I found your post on the kms driver and now after the daemon screen it boots into a high resolution. thanks.

I still get a no screens found trying to startx but i'm getting there.
 
Back
Top