/[gentoo]/xml/htdocs/doc/en/handbook/hb-install-ppc-kernel.xml
Gentoo

Diff of /xml/htdocs/doc/en/handbook/hb-install-ppc-kernel.xml

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

Revision 1.34 Revision 1.38
1<?xml version='1.0' encoding='UTF-8'?> 1<?xml version='1.0' encoding='UTF-8'?>
2<!DOCTYPE sections SYSTEM "/dtd/book.dtd"> 2<!DOCTYPE sections SYSTEM "/dtd/book.dtd">
3 3
4<!-- The content of this document is licensed under the CC-BY-SA license --> 4<!-- The content of this document is licensed under the CC-BY-SA license -->
5<!-- See http://creativecommons.org/licenses/by-sa/1.0 --> 5<!-- See http://creativecommons.org/licenses/by-sa/2.5 -->
6 6
7<!-- $Header: /var/cvsroot/gentoo/xml/htdocs/doc/en/handbook/hb-install-ppc-kernel.xml,v 1.34 2005/08/09 09:43:58 swift Exp $ --> 7<!-- $Header: /var/cvsroot/gentoo/xml/htdocs/doc/en/handbook/hb-install-ppc-kernel.xml,v 1.38 2006/01/08 14:05:29 neysx Exp $ -->
8 8
9<sections> 9<sections>
10 10
11<version>2.11</version> 11<version>2.15</version>
12<date>2005-08-09</date> 12<date>2006-01-06</date>
13 13
14<section> 14<section>
15<title>Timezone</title> 15<title>Timezone</title>
16<body> 16<body>
17 17
18<p> 18<p>
19First, select your timezone so that your system knows where it is located. Look 19You first need to select your timezone so that your system knows where it is
20for your timezone in <path>/usr/share/zoneinfo</path>, then make a symlink to 20located. Look for your timezone in <path>/usr/share/zoneinfo</path>, then copy
21<path>/etc/localtime</path> using <c>ln</c>: 21it to <path>/etc/localtime</path>. Please avoid the
22<path>/usr/share/zoneinfo/Etc/GMT*</path> timezones as their names do not
23indicate the expected zones. For instance, <path>GMT-8</path> is in fact GMT+8.
22</p> 24</p>
23 25
24<pre caption="Setting the timezone information"> 26<pre caption="Setting the timezone information">
25# <i>ls /usr/share/zoneinfo</i> 27# <i>ls /usr/share/zoneinfo</i>
26<comment>(Suppose you want to use GMT)</comment> 28<comment>(Suppose you want to use GMT)</comment>
27# <i>ln -sf /usr/share/zoneinfo/GMT /etc/localtime</i> 29# <i>cp /usr/share/zoneinfo/GMT /etc/localtime</i>
28</pre> 30</pre>
29 31
30</body> 32</body>
31</section> 33</section>
32<section> 34<section>
42available at the <uri link="/doc/en/gentoo-kernel.xml">Gentoo Kernel 44available at the <uri link="/doc/en/gentoo-kernel.xml">Gentoo Kernel
43Guide</uri>. 45Guide</uri>.
44</p> 46</p>
45 47
46<p> 48<p>
47We suggest using either <c>vanilla-sources</c> or <c>gentoo-sources</c> 49We suggest using either <c>vanilla-sources</c> or <c>gentoo-sources</c> on PPC,
48on PPC, which are both 2.6 kernels. The latter is available when you 50which are both 2.6 kernels. The latter is available when you perform a
49perform a networkless installation. So let's continue with <c>emerge</c>'ing 51networkless installation. So let's continue with <c>emerge</c>'ing the kernel
50the kernel sources: 52sources. The <c>USE="-doc"</c> is necessary to avoid installing xorg-x11 or
53other dependencies at this point. <c>USE="symlink"</c> is not necessary for a
54new install, but ensures proper creation of the <path>/usr/src/linux</path>
55symlink.
51</p> 56</p>
52 57
53<pre caption="Installing the kernel source"> 58<pre caption="Installing the kernel source">
54# <i>emerge gentoo-sources</i> 59# <i>USE="-doc symlink" emerge gentoo-sources</i>
55</pre> 60</pre>
56 61
62<!-- Removed, as we're trying to avoid specific kernel versions to improve HB
63maintainability
57<note> 64<note>
58The suggested sources at the time of the 2005.1 release are 65The suggested sources at the time of the 2005.1 release are
59<c>gentoo-sources-2.6.12-r4</c> and <c>vanilla-sources-2.6.12.2</c>. 66<c>gentoo-sources-2.6.12-r4</c> and <c>vanilla-sources-2.6.12.2</c>.
60</note> 67</note>
68-->
61 69
62<p> 70<p>
63If you take a look in <path>/usr/src</path> you should see a symlink named 71If you take a look in <path>/usr/src</path> you should see a symlink named
64<path>linux</path> pointing to your current kernel source. Here, we will assume 72<path>linux</path> pointing to your current kernel source. In this case, the
65that the kernel source installed is <c>gentoo-sources-2.6.12-r4</c>: 73installed kernel source points to <c>gentoo-sources-2.6.12-r4</c>. Your version
74may be different, so keep this in mind.
66</p> 75</p>
67 76
68<pre caption="Viewing the kernel source symlink"> 77<pre caption="Viewing the kernel source symlink">
69# <i>ls -l /usr/src/linux</i> 78# <i>ls -l /usr/src/linux</i>
70lrwxrwxrwx 1 root root 22 Mar 18 16:23 /usr/src/linux -&gt; linux-2.6.12-gentoo-r4 79lrwxrwxrwx 1 root root 22 Mar 18 16:23 /usr/src/linux -&gt; linux-2.6.12-gentoo-r4
71</pre>
72
73<p>
74If the symlink doesn't point to the kernel source of your choice (note that
75<c>linux-2.6.12-gentoo-r4</c> is merely an example) you should change it to the
76desired kernel sources:
77</p>
78
79<pre caption="Changing the kernel source symlink">
80# <i>rm /usr/src/linux</i>
81# <i>cd /usr/src</i>
82# <i>ln -s linux-2.6.12-gentoo-r4 linux</i>
83</pre> 80</pre>
84 81
85<p> 82<p>
86It is now time to configure and compile your kernel source. You can use 83It is now time to configure and compile your kernel source. You can use
87<c>genkernel</c> to build a generic kernel similar to the one used by the 84<c>genkernel</c> to build a generic kernel similar to the one used by the
110Linux user ever has to perform. Nothing is less true, after configuring a 107Linux user ever has to perform. Nothing is less true, after configuring a
111couple of kernels you won't even remember it being that difficult ;) 108couple of kernels you won't even remember it being that difficult ;)
112</p> 109</p>
113 110
114<p> 111<p>
115Building a successful you must know what is in your system when 112However, one thing <e>is</e> true: you must know your system when you start
116you start configuring a kernel manually. Most information can be gathered by 113configuring a kernel manually. Most information can be gathered by emerging
117emerging pciutils <c>emerge pciutils</c> which contains <c>lspci</c>. You 114pciutils (<c>emerge pciutils</c>) which contains <c>lspci</c>. You will now
118can
119be able to use <c>lspci</c> within the chrooted environment. You may safely 115be able to use <c>lspci</c> within the chrooted environment. You may safely
120ignore any <e>pcilib</e> warnings (like pcilib: cannot open 116ignore any <e>pcilib</e> warnings (like pcilib: cannot open
121/sys/bus/pci/devices) that <c>lspci</c> throws out. Alternatively, you can run 117/sys/bus/pci/devices) that <c>lspci</c> throws out. Alternatively, you can run
122<c>lspci</c> from a <e>non-chrooted</e> environment. The results are the same. 118<c>lspci</c> from a <e>non-chrooted</e> environment. The results are the same.
123You can also run <c>lsmod</c> to see what kernel modules the Installation CD 119You can also run <c>lsmod</c> to see what kernel modules the Installation CD
126message logs from the successful boot that got you this far. Type <c>dmesg</c> 122message logs from the successful boot that got you this far. Type <c>dmesg</c>
127to see the kernel messages. 123to see the kernel messages.
128</p> 124</p>
129 125
130<p> 126<p>
131Now go to your kernel source directory and execute <c>make menuconfig</c>. This 127Now go to your kernel source directory, it's time to configure your kernel. It
132will fire up an ncurses-based configuration menu. 128is recommended that you add the default settings to your configuration by first
129running <c>make defconfig</c>. After the default configuration has been
130generated, run <c>make menuconfig</c> which will fire up an ncurses-based
131configuration menu.
133</p> 132</p>
134 133
135<pre caption="Invoking menuconfig"> 134<pre caption="Invoking menuconfig">
136# <i>cd /usr/src/linux</i> 135# <i>cd /usr/src/linux</i>
136# <i>make defconfig</i>
137# <i>make menuconfig</i> 137# <i>make menuconfig</i>
138</pre> 138</pre>
139 139
140<p> 140<p>
141You will be greeted with several configuration sections. We'll first list some 141You will be greeted with several configuration sections. We'll first list some
163 163
164<p> 164<p>
165Now go to <c>File Systems</c> and select support for the filesystems you use. 165Now go to <c>File Systems</c> and select support for the filesystems you use.
166<e>Don't</e> compile them as modules, otherwise your Gentoo system will not be 166<e>Don't</e> compile them as modules, otherwise your Gentoo system will not be
167able to mount your partitions. Also select <c>/proc file system</c> and 167able to mount your partitions. Also select <c>/proc file system</c> and
168<c>Virtual memory</c>. Do <e>not</e> select the <c>/dev file system</c>. 168<c>Virtual memory</c>.
169</p> 169</p>
170 170
171<pre caption="Selecting necessary file systems"> 171<pre caption="Selecting necessary file systems">
172File systems ---&gt; 172File systems ---&gt;
173 Pseudo Filesystems ---&gt; 173 Pseudo Filesystems ---&gt;
174 [*] /proc file system support 174 [*] /proc file system support
175 [ ] /dev file system support (OBSOLETE)
176 [*] Virtual memory file system support (former shm fs) 175 [*] Virtual memory file system support (former shm fs)
177 176
178<comment>(Select one or more of the following options as needed by your system)</comment> 177<comment>(Select one or more of the following options as needed by your system)</comment>
179 &lt;*&gt; Second extended fs support 178 &lt;*&gt; Second extended fs support
180 &lt;*&gt; Ext3 journalling file system support 179 &lt;*&gt; Ext3 journalling file system support
306When the kernel has finished compiling, copy the kernel image to 305When the kernel has finished compiling, copy the kernel image to
307<path>/boot</path> (be sure that it is mounted properly on the Pegasos). 306<path>/boot</path> (be sure that it is mounted properly on the Pegasos).
308</p> 307</p>
309 308
310<pre caption="Installing the kernel"> 309<pre caption="Installing the kernel">
311<comment>replace 2.6.12 with your kernel-version</comment> 310<comment>replace &lt;kernel-version&gt; with your kernel version</comment>
312(Apple/IBM) # <i>cp vmlinux /boot/kernel-2.6.12</i> 311(Apple/IBM) # <i>cp vmlinux /boot/&lt;kernel-version&gt;</i>
313(Pegasos) # <i>cp arch/ppc/boot/images/zImage.chrp /boot/kernel-2.6.12</i> 312(Pegasos) # <i>cp arch/ppc/boot/images/zImage.chrp /boot/&lt;kernel-version&gt;</i>
314</pre>
315
316<p>
317It is also wise to copy over your kernel configuration file to
318<path>/boot</path>, just in case :)
319</p>
320
321<pre caption="Backing up your kernel configuration">
322# <i>cp .config /boot/config-2.6.12-gentoo-r4</i>
323</pre> 313</pre>
324 314
325<p> 315<p>
326Now continue with <uri link="#kernel_modules">Installing Separate Kernel 316Now continue with <uri link="#kernel_modules">Installing Separate Kernel
327Modules</uri>. 317Modules</uri>.
454before your "real" system starts up. Be sure to also copy down the required 444before your "real" system starts up. Be sure to also copy down the required
455boot arguments, these are required for a successful boot with genkernel. 445boot arguments, these are required for a successful boot with genkernel.
456</p> 446</p>
457 447
458<pre caption="Checking the created kernel image name and initrd"> 448<pre caption="Checking the created kernel image name and initrd">
459# <i>ls /boot/kernel* /boot/initrd*</i> 449# <i>ls /boot/kernel* /boot/initramfs*</i>
460</pre> 450</pre>
461 451
462<p> 452<p>
463Now, let's perform one more step to get our system to be more like the 453Now, let's perform one more step to get our system to be more like the
464Installation CD -- let's emerge <c>coldplug</c>. While the initrd autodetects 454Installation CD -- let's emerge <c>coldplug</c>. While the initrd autodetects

Legend:
Removed from v.1.34  
changed lines
  Added in v.1.38

  ViewVC Help
Powered by ViewVC 1.1.20