3 ms·
That bootloader needs to mount a filesystem to find the kernel. The kernel needs to mount the filesystem to run the system. Each of those mount operations is
by cperciva 3y ago
That bootloader needs to mount a filesystem to find the kernel.
The kernel needs to mount the filesystem to run the system.
Each of those mount operations is done with different code...
Not on FreeBSD. Our bootloader reuses kernel code (because, you know, developing the entire operating system together makes this possible).
- somat 3y agoI always feel one of the under appreciated features of zfs on freebsd was how nicely it was integrated into the whole operating system. that is, it is easy to boot off a zfs drive in freebsd.
- ahesford 3y agoZFSBootMenu "reuses kernel code", too. It actually reuses kernel binaries, because it is nothing more than a collection of init scripts in a small Linux initramfs to enumerate ZFS filesystems and allow you to kexec one of the kernels found within. When using `generate-zbm` to build a custom image, your copy of ZFSBootMenu will use the very same kernel and ZFS driver that your system is running. When using the the prebuilt UEFI or separate kernel/initramfs that we provide as a convenience, the image is built from a Void Linux container using whatever kernel and ZFS driver was current at the time the container image was created. I'm not sure what the complaints are about mounting filesystems. Unless you want to raw-dump your kernel and other components necessary for booting to some known offset on the disk, you'll always have to walk some filesystem to find the kernel. This even happens in the FreeBSD boot process, where one of the stages has to go looking at the filesystem for a kernel.