Re: custom install and missing kenv defaults

From: Warner Losh <imp_at_bsdimp.com>
Date: Sun, 06 Mar 2022 21:11:28 UTC
On Sun, Mar 6, 2022 at 1:17 PM Eugene M. Zheganin <eugene@zhegan.in> wrote:

> Hello,
>
> I'm using custom install script for setting up FreeBSD on large disks
> (you know, that 10-years-ago-and-still-there issue with "cannnot read
> MOS, all block copies unavailable" when book blocks migrate over 2TB),
> but I was using it only on legacy gptzfsboot servers, Nowadays I
> converted it to UEFI, and now I can see that this installation cannot
> boot atomatically, because it searches for the kernel in /boot. I know
> about loader.conf, for sure, but servers installed with bsdinstall don't
> have kernel_path set there (along with module_path), yet it works fine.
> I've also checked the kernel for the bundled env variables - none.
>
> So, my question is - where are the kernel_path and module path set when
> the bsdinstall does the installation ?
>

They aren't. They default to the path that the boot loader reports to the
kernel.
/boot/loader.conf can, I believe, override them.

Warner