- Timestamp:
- Feb 21, 2006, 12:44:59 AM (19 years ago)
- Children:
- 91ffea1
- Parents:
- 164c9be
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
bootable/ppc/yaboot.xml
r164c9be ra625f8b 15 15 <secondary>configuring</secondary></indexterm> 16 16 17 <para>This is a place holder for configuring yaboot</para> 17 <para os="a">Your shiny new LFS system is almost complete. One of the last 18 things to do is to ensure that the system can be properly booted. The 19 instructions below apply only to NewWorld Macintoshes and (probably) 20 PegasosPPC.</para> 21 22 <para os="b">Boot loading can be a complex area, so a few cautionary words 23 are in order. Be familiar with the current boot loader and any other 24 operating systems present on the hard drive(s) that need to be bootable. 25 Make sure that an emergency CD is ready to <quote>rescue</quote> the 26 computer if it becomes un-bootable.</para> 27 28 <para os="c">Earlier, we compiled and installed the yaboot boot loader software 29 in preparation for this step. The procedure involves writing the bootloader 30 to a bootstrap partition and blessing it so that OpenFirmware will boot from 31 it. This is all handled by <command>ybin</command> the yaboot installer.</para> 32 33 <para os="d">Ybin assembles all the information it needs by reading yaboot.conf, 34 then writes the bootstrap. When booted, the bootstrap provides an initial menu to 35 choose between linux, boot from CD, and e.g. osx (depending on what was in yaboot.conf). 36 If you boot to 'linux', yaboot kicks in and lets you select which kernel to use.</para> 37 38 <para os="e">Images (kernels) are specified, together with any necessary path, 39 in yaboot.conf - the details are incorporated into the bootloader, but no attempt 40 is made to access or validate the paths until they are selected. There are many 41 possible options that can be specified in yaboot.conf, see the man page for the 42 details. Most people will be able to specify device=hd: (for a single hard disk), 43 but if you have multiple disks, or if you wish to be pedantic, you can specify the 44 full OF path to the device, obtained by running <command>ofpath</command>.</para> 45 46 <para os="f">Note that the man page mentions which filesystems yaboot can 47 navigate to find the images - the only linux filesystem type mentioned is ext2. 48 You can use ext3 because that can be read like ext2, but if you wish to use 49 reiserfs or any other filesystem you may need to create a separate boot partition 50 formatted as ext2.</para> 51 52 <para os="h">Using the above information, determine the appropriate designators 53 for the bootstrap partition and the root partition. For the following example, 54 it is assumed that the bootstrap partition is <filename class="partition">hda2 55 </filename> and the root partition is <filename class="partition">hda7</filename> 56 . We will also assume that you wish to be able to boot an OSX installation on 57 <filename class="partition">hda4</filename>. Change these items as necessary 58 for your machine.</para> 59 60 <para os="k">Create a <quote>yaboot.conf</quote> file defining yaboot's boot 61 menu:</para> 62 63 <screen os="l" role="nodump"><userinput>cat > /etc/yaboot.conf << "EOF" 64 <literal># Begin /etc/yaboot.conf 65 66 # By default, yaboot will boot the first menu entry. 67 68 # Allow 10 seconds before booting the default. 69 # this will also apply to the first-stage os selector 70 timeout 100 71 72 # These variables are global 73 # first, where to put the bootstrap partition 74 boot=/dev/hda2 75 76 # Which disk to use 77 device=hd: 78 79 # Default partition for the kernel images 80 partition=7 81 82 # default root partition 83 root=/dev/hda7 84 85 # where ybin is to find yaboot and ofboot 86 install=/usr/lib/yaboot/yaboot 87 magicboot=/usr/lib/yaboot/ofboot 88 89 # allow the initial menu to offer CD as an option 90 enablecdboot 91 92 # allow the initial menu to boot from mac osx 93 macosx=/dev/hda4 94 95 # The first entry is for LFS. 96 # For all images, the pathname is relative to the filesystem 97 # on which they are mounted. 98 image=/boot/lfskernel-&linux-ppc-version; 99 label=&version; 100 read-only</literal> 101 EOF</userinput></screen> 102 103 104 <para os="n">Add an entry for the host distribution, if you have one. It might 105 look something like this if the kernel and initrd are in the host's '/' 106 directory on <filename class="partition">hda6</filename>:</para> 107 108 <screen os="o" role="nodump"><userinput>cat >> /etc/yaboot.conf << "EOF" 109 <literal>title Debian 110 image=/pci@f4000000/ata-6d/disk@0:6,/vmlinux 111 label=Debian 112 initrd=/pci@f4000000/ata-6d/disk@0:6,/initrd.gz 113 initrd-size=10000 114 append="root=/dev/hda7" 115 read-only</literal> 116 EOF</userinput></screen> 117 118 <warning os="r"> 119 <para>The following command will overwrite the current boot loader. 120 Do not run the command if this is not desired.</para> 121 </warning> 122 123 <screen os="s" role="nodump"><userinput>ybin</userinput></screen> 18 124 19 125 </sect1>
Note:
See TracChangeset
for help on using the changeset viewer.