Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 08 Mar 2014 00:06:29 -0800
From:      Peter Grehan <grehan@freebsd.org>
To:        "Rudy (bulk)" <crapsh@monkeybrains.net>
Cc:        freebsd-virtualization@freebsd.org
Subject:   Re: [HOW-TO] CentOS on bhyve
Message-ID:  <531ACF85.8040305@freebsd.org>
In-Reply-To: <531AC763.300@monkeybrains.net>
References:  <531ABCC5.30801@monkeybrains.net> <531AC763.300@monkeybrains.net>

next in thread | previous in thread | raw e-mail | index | archive | help
Hi Rudy,

> Peter, anyway to get grub-bhyve to automatically load /grub/grub.conf
> from a CentOS install?
>
> A more concise boot how-to involves making a .grub file based on the
> contents of the grub.conf in your .img file.  The first email shows me
> wading through the grub prompt trying to figure out what to do.  I'm not
> sure if the SYSFONT is pertinent.  :)

  CentOS is grub v1 which isn't quite compatible with grub2 (e.g. linux 
-> kernel).

  grub-bhyve can pick up a config file from the host system: use "-r 
host" to force that, and the -d option to change the default path for 
grub.conf. No need to redirect input.

  Then, in grub.conf on the host, put in the absolute path with the grub 
commands e.g.

kernel (hd0,msdos1)/vmlinuz-2.6.32-431.el6.x86_64 ro 
root=/dev/mapper/VolGroup-lv_root rd_NO_LUKS LANG=en_US.UTF-8 rd_NO_MD 
KEYTABLE=us rd_LVM_LV=VolGroup/lv_swap SYSFONT=latarcyrheb-sun16 
crashkernel=auto rd_LVM_LV=VolGroup/lv_root rd_NO_DM
initrd (hd0,msdos1)/initramfs-2.6.32-431.el6.x86_64.img
boot

(the console=ttyS0 isn't needed: grub-bhyve auto-inserts that).

later,

Peter.



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?531ACF85.8040305>