[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Working grub.cfg for UEFI boot FreeBSD using GRUB on x86

From: Andrei Borzenkov
Subject: Re: Working grub.cfg for UEFI boot FreeBSD using GRUB on x86
Date: Mon, 3 Apr 2017 19:14:07 +0300
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:45.0) Gecko/20100101 Thunderbird/45.8.0

03.04.2017 15:07, HSR Hackspace пишет:
> Hi folks;
> I have a x86 machine with UEFI (secure boot disabled) running Freebsd
> 10.1.  I am trying to make it dual boot with Linux as second operating
> system. For that I'm trying to install freebsd port of grub ( from
> FreeBSD). Installation seems going fine with only problem being
> missing grub.cfg. I tried creating  post installation but I got empty
> file.
> -> grub-mkconfig -o /boot/grub/grub.cfg
> Generating grub configuration file ...
> /usr/local/etc/grub.d/00_header: cut: not found

You mean cut is missing from FreeBSD (presumably, default) install?
Well, in this case you need to file bug report in their bugzilla, grub
package should require whatever package provides this utility (sorry, I
am not familiar with how FreeBSD software is delivered so I may use
wrong terms). cut is used in several places, and I'm not sure there is
easy re-implementation using pure POSIX shell. And if cut is missing,
then we really cannot expect and other tool to be present.

> Above command generated file
> #
> #
> # It is automatically generated by grub-mkconfig using templates
> # from /usr/local/etc/grub.d and settings from /usr/local/etc/default/grub
> #
> ### BEGIN /usr/local/etc/grub.d/00_header ###
> For  work around I  manually created grb.cfg with below entry :
> menuentry "FreeBSD" {
>     insmod ufs2
> insmod bsd
> insmod gzio
> insmod efi_gop
>     insmod gfxterm
>     insmod font
>     insmod videotest
>     insmod videoinfo
>     set gfxmode=auto
>     set kernvt="vt"
>     set root=(hd0,3)
>     kfreebsd /boot/loader.efi
> }
> This end with error: invalid a.out header.

According to, the right binary would be
boot1.efi which locates and starts loader.efi. I would start with trying
this one.

kfreebsd loader loads FreeBSD kernel. I do not know if it will work
under UEFI (in case of Linux you still can use normal loader and it works).

> I think this may be due to file format mismatch between kfreebsd (
> a.out) and loader (efi). So I replaced loader.efi with simple loader
> file . But this time I got a blank screen (with white blurr on top of
> screen) . Not sure this is video issue or something else. Finally I
> replaced last line with chainloader /boot/loader.efi. This time result
> are more encouraging but booting got stuck with 'signature did not
> matched not booting'. Since we have disabled secure booting I am not
> expecting signature matching.

Please show exact message verbatim.

reply via email to

[Prev in Thread] Current Thread [Next in Thread]