Solved Fresh FreeBSD 11.0-RELEASE install - no boot [UEFI]

Atsuri

Active Member

Reaction score: 24
Messages: 137

I noticed there are some threads on booting problems, though none of them mentioned my specific issues. I have an ASUS S301A ultrabook with Intel Core i3 Haswell + Intel HD 4400 Graphics, Realtek 8169 Ethernet and Intel Centrino 5100 wireless. I used to run FreeBSD 10.3-RELEASE on it some time ago, though distro-hopped multiple times since then already.

Now I'm trying to do a fresh FreeBSD 11.0-RELEASE install to see how the new features may improve my day to day computing (mostly pertaining to Intel graphics, but not only). Unfortunately, I either cannot install or I end up with an unbootable system. One of the two scenarios follows:
A: I launch the installer, proceed through the many options in a more or less standard fashion and partition the hard drive thus:
500 GB GPT table:
Code:
/dev/ada0p1       efi      /boot      500 MB
/dev/ada0p2       freebsd-ufs     /      100GB
/dev/ada0p3       freebsd-swap      none      8GB
/dev/ada0p4       freebsd-ufs     /home     ~357 GB (rest)
Marking the efi partition to store the /boot mount point results in an error later on saying:
Code:
base.txz: Can't restore time
. This error is prevented when no mount point is assigned to the efi partition.

B: I don't assign a specific mount point to the efi partition as above and after completing the install, I end up with an unbootable system, with a bootloader error message saying:
Code:
ZFS found no pools
UFS found no partitions
Failed to load '/boot/loader.efi'
panic: no bootable partitions found!
Additional notes:
- I can disable "Fast Boot", though scenario B happens with Fast Boot enabled or disabled regardless
- Launching CSM mode (legacy BIOS?) post- or pre-install results in the same scenarios A and B

Any ideas?
 

SirDice

Administrator
Staff member
Administrator
Moderator

Reaction score: 8,775
Messages: 33,056

The EFI partition is a special partition, do not confuse it with either freebsd-boot or the contents of /boot.
 
OP
A

Atsuri

Active Member

Reaction score: 24
Messages: 137

The EFI partition is a special partition, do not confuse it with either freebsd-boot or the contents of /boot.
It's a bit different on GNU/Linux, where the EFI partition may contain /boot. That's what got me confused. Regardless, my system is unbootable after the install even if I select the default options :(.
 

asteriskRoss

Well-Known Member

Reaction score: 144
Messages: 438

It's a bit different on GNU/Linux, where the EFI partition may contain /boot
Atsuri, it is possible (that is, in an ugly hack way) to store the contents of /boot on the EFI partition with FreeBSD but I really wouldn't recommend it. I'm not sure I'd be comfortable with it for GNU/Linux either but since this is a FreeBSD forum let's ignore that for now :) I would suggest not assigning a mount point for the EFI partition and letting the /boot directory reside on the root filesystem where it naturally belongs.

my system is unbootable after the install even if I select the default options :(.
What console output do you see on boot? Have you removed the installation media? Have you configured your BIOS for UEFI boot with secure boot disabled?
 
OP
A

Atsuri

Active Member

Reaction score: 24
Messages: 137

What console output do you see on boot? Have you removed the installation media? Have you configured your BIOS for UEFI boot with secure boot disabled?
I did remove the installation USB stick, yes. Secure Boot is off as well. The output I see on boot is in my first post. Again, if I don't mess around with the efi partition and just let the partitioner do its magic, things end up following scenario B.
 

asteriskRoss

Well-Known Member

Reaction score: 144
Messages: 438

The good news from your bootloader message is that the first stage UEFI bootloader is running fine. The bad news is that it then can't find the next stage bootloader, which lives inside /boot. It seems unlikely to me (though it is possible) that this would be a general flaw in the FreeBSD release installer as I would have hoped it would have been caught in testing.

I launch the installer, proceed through the many options in a more or less standard fashion and partition the hard drive
I wonder whether you would try removing the existing partitions on the disk and proceeding from scratch through the installer in a "more" standard fashion, that is, leaving everything at default. If your PC can boot, then something that you changed to be "less" standard is causing your issue. If it can't, then we can look in more detail at what the installer is doing and why it is not working for you. I appreciate a default installation may not suit you exactly but you can always reinstall later once you have ensured it works at all.
 
OP
A

Atsuri

Active Member

Reaction score: 24
Messages: 137

The good news from your bootloader message is that the first stage UEFI bootloader is running fine. The bad news is that it then can't find the next stage bootloader, which lives inside /boot. It seems unlikely to me (though it is possible) that this would be a general flaw in the FreeBSD release installer as I would have hoped it would have been caught in testing.

I wonder whether you would try removing the existing partitions on the disk and proceeding from scratch through the installer in a "more" standard fashion, that is, leaving everything at default. If your PC can boot, then something that you changed to be "less" standard is causing your issue. If it can't, then we can look in more detail at what the installer is doing and why it is not working for you. I appreciate a default installation may not suit you exactly but you can always reinstall later once you have ensured it works at all.
So I did some additional testing and it turned out that I'm simply not very observant. Although it's not how a default UEFI partitioning scheme should look like (per what bsdinstall suggests), apparently both the installation USB stick and my hard drive required that there be an additional small "freebsd-boot" partition without a specified mount point just like the efi partition discussed earlier. The system booted in UEFI-mode with the following scheme:
Code:
/dev/ada0p1       efi      200MB
/dev/ada0p2       freebsd-boot     200MB
/dev/ada0p3       freebsd-ufs     /      100GB
/dev/ada0p4       freebsd-swap    8GB
/dev/ada0p5       freebsd-ufs     /home     ~356 GB (rest)
Might be useful for others with similar issues. It seems FreeBSD is far more reasonable in that sense than GNU/Linux :).
Thread marked as SOLVED.
 

asteriskRoss

Well-Known Member

Reaction score: 144
Messages: 438

I wouldn't expect you to need a freebsd-boot partition when using the UEFI bootloader so I'm not sure that was the cause of the issue. Did you try installing with the default partitioning proposed by the installer as I suggested?

In previous releases the *-memstick image has been a hybrid offering both UEFI and MBR booting capabilities which is why it included one (though I've not specifically looked at 11.0 yet).
 
OP
A

Atsuri

Active Member

Reaction score: 24
Messages: 137

I wouldn't expect you to need a freebsd-boot partition when using the UEFI bootloader so I'm not sure that was the cause of the issue. Did you try installing with the default partitioning proposed by the installer as I suggested?

In previous releases the *-memstick image has been a hybrid offering both UEFI and MBR booting capabilities which is why it included one (though I've not specifically looked at 11.0 yet).
1. Yes, I have actually mentioned that the installer recommends only the efi partition per boot requirements and unfortunately this yields an unbootable system. It also baffles me that I need a freebsd-boot partition in addition to make the system work.

2. 1-2 years ago there were UEFI and non-UEFI images as back then UEFI was still new in FreeBSD. I remember trying out the UEFI capable memstick image, but I still had to install FreeBSD in legacy BIOS mode as my laptop's UEFI implementation was quite finicky. The freebsd-boot partition was enough.

Now I'm running FreeBSD 11.0-RELEASE in UEFI mode, though with both the efi and freebsd-boot partitions as otherwise the system would be stuck during early boot trying to find the /boot content. Thanks a lot for helping me figure this out! Appreciated :).
 

kpa

Beastie's Twin

Reaction score: 1,818
Messages: 6,318

So which boot mode are you using? If you switch the UEFI firmware to the legacy BIOS booting you will need a freebsd-boot partition. If the boot is pure UEFI the boot loader gets loaded solely from the EFI partition.
 
OP
A

Atsuri

Active Member

Reaction score: 24
Messages: 137

So which boot mode are you using? If you switch the UEFI firmware to the legacy BIOS booting you will need a freebsd-boot partition. If the boot is pure UEFI the boot loader gets loaded solely from the EFI partition.
I'm using UEFI-mode together with my laptop's Fast Boot option. Everything, including the Haswell-based Intel HD 4400 works.
 

christhegeek

Active Member

Reaction score: 17
Messages: 124

Is there a way to boot freebsd from nonefi partition (freebsd-boot) ? My laptop is an Asus Vivobook (ryzen3 vega3) and booting efi and amdgpu is a complete disaster !
By default xorg doesnt start it says something about an address (framebuffer?).
If i set the hw.syscons.disable=1 then sometimes i managed it to start but then stopped and doesn't start xorg or do anything anymore.....
It stucks in EFI Framework information and doesn't start xorg , also i can't switch to any terminal its like its frozen but when i press power button after a while it shuts down .
What's happening ??????
Am i able to stop using efi on this laptop can i use freebsd-boot ?
 

asteriskRoss

Well-Known Member

Reaction score: 144
Messages: 438

Hi, christhegeek, it sounds like you have a range of issues there. If you want some help solving the issues with your boot console and/or x11/xorg then it might be best to start a new thread. I'd suggest beginning with the boot console issues, though it would be helpful if you could provide more information about what you're seeing and what you've tried.

To answer your specific question about using MBR boot rather than UEFI boot on your Asus Vivobook, then I believe this is possible by changing the "CSM Support" option in the "Boot" section of the BIOS utility, which should be visible in "Advanced" mode, likely enabled by pressing F7. CSM stands for Compatibility Support Module.

However, FreeBSD support for UEFI is now pretty good IMHO so it might be worth persevering to see if you can make it work.
 

christhegeek

Active Member

Reaction score: 17
Messages: 124

There is no such option on bios only secure boot option !

Hi, christhegeek, it sounds like you have a range of issues there. If you want some help solving the issues with your boot console and/or x11/xorg then it might be best to start a new thread. I'd suggest beginning with the boot console issues, though it would be helpful if you could provide more information about what you're seeing and what you've tried.

To answer your specific question about using MBR boot rather than UEFI boot on your Asus Vivobook, then I believe this is possible by changing the "CSM Support" option in the "Boot" section of the BIOS utility, which should be visible in "Advanced" mode, likely enabled by pressing F7. CSM stands for Compatibility Support Module.

However, FreeBSD support for UEFI is now pretty good IMHO so it might be worth persevering to see if you can make it work.
 

asteriskRoss

Well-Known Member

Reaction score: 144
Messages: 438

Hmmmm... Assuming that you already tried switching off the secure boot option and no more options magically appeared, it is looking like your Asus Vivobook only supports UEFI booting. You could confirm by finding the user manual for your precise model.
 
Top