Handbook:IA64/Installation/Bootloader

From Gentoo Wiki
Jump to:navigation Jump to:search
IA64 Handbook
Installation
About the installation
Choosing the media
Configuring the network
Preparing the disks
The stage file
Installing base system
Configuring the kernel
Configuring the system
Installing tools
Configuring the bootloader
Finalizing
Working with Gentoo
Portage introduction
USE flags
Portage features
Initscript system
Environment variables
Working with Portage
Files and directories
Variables
Mixing software branches
Additional tools
Custom package repository
Advanced features
OpenRC network configuration
Getting started
Advanced configuration
Modular networking
Wireless
Adding functionality
Dynamic management



Installing elilo

IA64 platform are EFI platforms. At least the following boot loader applications are known to work: elilo and grub.

elilo (old and tested)

root #emerge --ask sys-boot/elilo

Its configuration file is called /etc/elilo.conf and a sample file is installed in the typical docs directory (/usr/share/doc/elilo-<version>/). Here is another sample configuration:

FILE /etc/elilo.confExample elilo configuration
boot=/dev/sda1
delay=30
timeout=50
default=Gentoo
append="console=ttyS0,9600"
prompt
  
image=/vmlinuz
	label=Gentoo
	root=/dev/sda3
	read-only
  
image=/vmlinuz.old
	label=Gentoo.old
	root=/dev/sda3
	read-only

The boot line tells elilo the location of the boot partition (in this case, /dev/sda1). The delay line sets the number of 10th of seconds before automatically booting the default when in non-interactive mode. The timeout line is just like the delay line but for interactive mode. The default line sets the default kernel entry (which is defined below). The append line adds extra options to the kernel command line. The prompt sets the default elilo behavior to interactive.

The sections that start with image define different bootable images. Each image has a nice label, a root filesystem, and will only mount the root filesystem read-only.

If, while building the Linux kernel, an initramfs was also configured to boot from, then it is necessary to change the configuration by referring to this initramfs file and telling the initramfs where the root device is at:

FILE /etc/elilo.confUpdated configuration to reflect use of initramfs
image=/vmlinuz
	label=Gentoo
	initrd=/initramfs-genkernel-ia64-3.16.5-gentoo
	append="initrd=initramfs-genkernel-ia64-3.16.5-gentoo root=/dev/sda3 console=ttyS0,9600"
	read-only

When the configuration is done, run elilo --efiboot. The --efiboot option adds a menu entry for Gentoo Linux to the EFI Boot Manager:

root #elilo --efiboot

GRUB (new and shiny)

The setup is a generic efi-64 process (tested at least on rx3600). Enable efi-64 application for grub:

FILE /etc/portage/make.conf
GRUB_PLATFORMS=efi-64

Install grub package:

root #emerge --ask sys-boot/grub

Install grub EFI application:

root #grub-install

This will install grubia64.efi into /boot/efi (default EFI partition location).

Generate bootloader config with menu entries:

root #grub-mkconfig --output=/boot/grub/grub.cfg

Add an EFI boot entry to run /EFI/gentoo/grubia64.efi as a boot loader. TODO: provide exact Efibootmgr command that adds an entry.


Rebooting the system

Exit the chrooted environment and unmount all mounted partitions. Then type in that one magical command that initiates the final, true test: reboot.

(chroot) livecd #exit
livecd~#cd
livecd~#umount -l /mnt/gentoo/dev{/shm,/pts,}
livecd~#umount -R /mnt/gentoo
livecd~#reboot

Do not forget to remove the live image, otherwise it may be targeted again instead of the newly installed Gentoo system!

Once rebooted in the fresh Gentoo environment, it is wise to finish with Finalizing the Gentoo installation.