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

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

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

Revision 1.15 Revision 1.30
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-alpha-kernel.xml,v 1.15 2004/12/26 14:32:07 swift Exp $ --> 7<!-- $Header: /var/cvsroot/gentoo/xml/htdocs/doc/en/handbook/hb-install-alpha-kernel.xml,v 1.30 2005/08/21 17:47:46 neysx Exp $ -->
8 8
9<sections> 9<sections>
10 10
11<version>1.12</version> 11<version>2.8</version>
12<date>2004-12-26</date> 12<date>2005-08-21</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>
19You first need to select your timezone so that your system knows where it is 19You first need to select your timezone so that your system knows where it is
20located. Look for your timezone in <path>/usr/share/zoneinfo</path>, then make a 20located. Look for your timezone in <path>/usr/share/zoneinfo</path>, then make
21symlink to <path>/etc/localtime</path> using <c>ln</c>: 21a symlink to <path>/etc/localtime</path> using <c>ln</c>. 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>
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>
47For alpha-based systems we have <c>vanilla-sources</c> (the default kernel 49For alpha-based systems we have <c>vanilla-sources</c> (the default 2.6 kernel source).
48source as developed by the linux-kernel developers), <c>alpha-sources</c>
49(kernel source optimized for alpha users) and <c>compaq-sources</c> (kernel
50source as used by RedHat for Alpha, maintained by Compaq).
51</p> 50</p>
52 51
53<p> 52<p>
54Choose your kernel source and install it using <c>emerge</c>. 53Choose your kernel source and install it using <c>emerge</c>.
55</p> 54</p>
68<path>linux</path> pointing to your kernel source: 67<path>linux</path> pointing to your kernel source:
69</p> 68</p>
70 69
71<pre caption="Viewing the kernel source symlink"> 70<pre caption="Viewing the kernel source symlink">
72# <i>ls -l /usr/src/linux</i> 71# <i>ls -l /usr/src/linux</i>
73lrwxrwxrwx 1 root root 12 Oct 13 11:04 /usr/src/linux -&gt; linux-2.4.24 72lrwxrwxrwx 1 root root 12 Oct 13 11:04 /usr/src/linux -&gt; linux-2.6.11.2
74</pre> 73</pre>
75 74
76<p> 75<p>
77If this isn't the case (i.e. the symlink points to a different kernel source) 76If this isn't the case (i.e. the symlink points to a different kernel source)
78change the symlink before you continue: 77change the symlink before you continue:
79</p> 78</p>
80 79
81<pre caption="Changing the kernel source symlink"> 80<pre caption="Changing the kernel source symlink">
82# <i>rm /usr/src/linux</i> 81# <i>rm /usr/src/linux</i>
83# <i>cd /usr/src</i> 82# <i>cd /usr/src</i>
84# <i>ln -s linux-2.4.24 linux</i> 83# <i>ln -s linux-2.6.11.2 linux</i>
85</pre> 84</pre>
86 85
87<p> 86<p>
88Now it is time to configure and compile your kernel source. You 87Now it is time to configure and compile your kernel source. You
89can use <c>genkernel</c> for this, which will build a generic kernel as used 88can use <c>genkernel</c> for this, which will build a generic kernel as used
90by the LiveCD. We explain the "manual" configuration first though, as it is 89by the Installation CD. We explain the "manual" configuration first though, as it is
91the best way to optimize your environment. 90the best way to optimize your environment.
92</p> 91</p>
93 92
94<p> 93<p>
95If you want to manually configure your kernel, continue now with <uri 94If you want to manually configure your kernel, continue now with <uri
113couple of kernels you don't even remember that it was difficult ;) 112couple of kernels you don't even remember that it was difficult ;)
114</p> 113</p>
115 114
116<p> 115<p>
117However, one thing <e>is</e> true: you must know your system when you start 116However, one thing <e>is</e> true: you must know your system when you start
118configuring a kernel manually. Most information can be gathered by viewing the 117configuring a kernel manually. Most information can be gathered by emerging
119contents of <path>/proc/pci</path> (or by using <c>lspci</c> if available). You 118pciutils (<c>emerge pciutils</c>) which contains <c>lspci</c>. You will now
119be able to use <c>lspci</c> within the chrooted environment. You may safely
120ignore any <e>pcilib</e> warnings (like pcilib: cannot open
121/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.
120can also run <c>lsmod</c> to see what kernel modules the LiveCD uses (it might 123You can also run <c>lsmod</c> to see what kernel modules the Installation CD
121provide you with a nice hint on what to enable). 124uses (it might provide you with a nice hint on what to enable).
122</p> 125</p>
123 126
124<p> 127<p>
125Now go to your kernel source directory and execute <c>make menuconfig</c>. This 128Now go to your kernel source directory and execute <c>make menuconfig</c>. This
126will fire up an ncurses-based configuration menu. 129will fire up an ncurses-based configuration menu.
146<p> 149<p>
147First of all, activate the use of development and experimental code/drivers. 150First of all, activate the use of development and experimental code/drivers.
148You need this, otherwise some very important code/drivers won't show up: 151You need this, otherwise some very important code/drivers won't show up:
149</p> 152</p>
150 153
151<pre caption="Selecting experimental code/drivers"> 154<pre caption="Selecting experimental code/drivers, General setup">
152Code maturity level options ---&gt; 155Code maturity level options ---&gt;
153 [*] Prompt for development and/or incomplete code/drivers 156 [*] Prompt for development and/or incomplete code/drivers
157General setup ---&gt;
158 [*] Support for hot-pluggable devices
154</pre> 159</pre>
155 160
156<p> 161<p>
157Now go to <c>File Systems</c> and select support for the filesystems you use. 162Now go to <c>File Systems</c> and select support for the filesystems you use.
158<e>Don't</e> compile them as modules, otherwise your Gentoo system will not be 163<e>Don't</e> compile them as modules, otherwise your Gentoo system will not be
159able to mount your partitions. Also select <c>Virtual memory</c>, <c>/proc 164able to mount your partitions. Also select <c>Virtual memory</c> and <c>/proc
160file system</c>, <c>/dev file system</c> + <c>Automatically mount at boot</c>: 165file system</c>. If you are using a 2.4 kernel, you should also select the
166<c>/dev file system</c> and <c>Automatically mount at boot</c> options, and
167you should make sure to <c>emerge devfsd</c>.
161</p> 168</p>
162 169
163<pre caption="Selecting necessary file systems"> 170<pre caption="Selecting necessary file systems">
164<comment>(With a 2.4.x kernel)</comment> 171<comment>(With a 2.4.x kernel)</comment>
165File systems ---&gt; 172File systems ---&gt;
171 178
172<comment>(With a 2.6.x kernel)</comment> 179<comment>(With a 2.6.x kernel)</comment>
173File systems ---&gt; 180File systems ---&gt;
174 Pseudo Filesystems ---&gt; 181 Pseudo Filesystems ---&gt;
175 [*] /proc file system support 182 [*] /proc file system support
176 [*] /dev file system support (OBSOLETE) 183 [ ] /dev file system support (OBSOLETE)
177 [*] Automatically mount at boot
178 [*] Virtual memory file system support (former shm fs) 184 [*] Virtual memory file system support (former shm fs)
179 185
180<comment>(Select one or more of the following options as needed by your system)</comment> 186<comment>(Select one or more of the following options as needed by your system)</comment>
181 &lt;*&gt; Reiserfs support 187 &lt;*&gt; Reiserfs support
182 &lt;*&gt; Ext3 journalling file system support 188 &lt;*&gt; Ext3 journalling file system support
285<title>Compiling and Installing</title> 291<title>Compiling and Installing</title>
286<body> 292<body>
287 293
288<p> 294<p>
289Now that your kernel is configured, it is time to compile and install it. Exit 295Now that your kernel is configured, it is time to compile and install it. Exit
290the configuration and run <c>make dep &amp;&amp; make vmlinux modules 296the configuration and start the compilation process:
291modules_install</c>:
292</p> 297</p>
293 298
294<pre caption="Compiling the kernel"> 299<pre caption="Compiling the kernel">
295<comment>(For 2.4 kernel)</comment> 300<comment>(For 2.4 kernel)</comment>
296# <i>make dep &amp;&amp; make vmlinux modules modules_install</i> 301# <i>make dep &amp;&amp; make vmlinux modules modules_install</i>
303</pre> 308</pre>
304 309
305<p> 310<p>
306When the kernel has finished compiling, copy the kernel image to 311When the kernel has finished compiling, copy the kernel image to
307<path>/boot</path>. In the next example we assume you have configured and 312<path>/boot</path>. In the next example we assume you have configured and
308compiled <c>vanilla-sources-2.4.24</c>; recent kernels might create 313compiled <c>vanilla-sources-2.6.11.2</c>; recent kernels might create
309<path>vmlinux</path> instead of <path>vmlinux.gz</path>. 314<path>vmlinux</path> instead of <path>vmlinux.gz</path>.
310</p> 315</p>
311 316
312<pre caption="Installing the kernel"> 317<pre caption="Installing the kernel">
313# <i>cp arch/alpha/boot/vmlinux.gz /boot/</i> 318# <i>cp arch/alpha/boot/vmlinux.gz /boot/</i>
314# <i>cp System.map /boot/System.map-2.4.24</i> 319# <i>cp System.map /boot/System.map-2.6.11.2</i>
315</pre> 320</pre>
316 321
317<p> 322<p>
318It is also wise to copy over your kernel configuration file to 323It is also wise to copy over your kernel configuration file to
319<path>/boot</path>, just in case :) 324<path>/boot</path>, just in case :)
320</p> 325</p>
321 326
322<pre caption="Backing up your kernel configuration"> 327<pre caption="Backing up your kernel configuration">
323# <i>cp .config /boot/config-2.4.24</i> 328# <i>cp .config /boot/config-2.6.11.2</i>
324</pre> 329</pre>
325 330
326<p> 331<p>
327Now continue with <uri link="#kernel_modules">Installing Separate Kernel 332Now continue with <uri link="#kernel_modules">Installing Separate Kernel
328Modules</uri>. 333Modules</uri>.
342 347
343<p> 348<p>
344Now that your kernel source tree is installed, it's now time to compile your 349Now that your kernel source tree is installed, it's now time to compile your
345kernel by using our <c>genkernel</c> script to automatically build a kernel for 350kernel by using our <c>genkernel</c> script to automatically build a kernel for
346you. <c>genkernel</c> works by configuring a kernel nearly identically to the 351you. <c>genkernel</c> works by configuring a kernel nearly identically to the
347way our LiveCD kernel is configured. This means that when you use 352way our Installation CD kernel is configured. This means that when you use
348<c>genkernel</c> to build your kernel, your system will generally detect all 353<c>genkernel</c> to build your kernel, your system will generally detect all
349your hardware at boot-time, just like our Live CD does. Because genkernel 354your hardware at boot-time, just like our Installation CD does. Because genkernel
350doesn't require any manual kernel configuration, it is an ideal solution for 355doesn't require any manual kernel configuration, it is an ideal solution for
351those users who may not be comfortable compiling their own kernels. 356those users who may not be comfortable compiling their own kernels.
352</p> 357</p>
353 358
354<p> 359<p>
374 379
375<pre caption="Running genkernel"> 380<pre caption="Running genkernel">
376# <i>genkernel all</i> 381# <i>genkernel all</i>
377GenKernel v3.0.1_beta10 382GenKernel v3.0.1_beta10
378* ARCH: Alpha 383* ARCH: Alpha
379* KERNEL VER: 2.4.24 384* KERNEL VER: 2.6.11.2
380* kernel: configuring source 385* kernel: configuring source
381* kernel: running mrproper 386* kernel: running mrproper
382<comment>(Output removed to increase readability)</comment> 387<comment>(Output removed to increase readability)</comment>
383* Kernel compiled successfully! 388* Kernel compiled successfully!
384* Required Kernel Params: 389* Required Kernel Params:
401Once <c>genkernel</c> completes, a kernel, full set of modules and 406Once <c>genkernel</c> completes, a kernel, full set of modules and
402<e>initial root disk</e> (initrd) will be created. We will use the kernel 407<e>initial root disk</e> (initrd) will be created. We will use the kernel
403and initrd when configuring a boot loader later in this document. Write 408and initrd when configuring a boot loader later in this document. Write
404down the names of the kernel and initrd as you will need it when writing 409down the names of the kernel and initrd as you will need it when writing
405the bootloader configuration file. The initrd will be started immediately after 410the bootloader configuration file. The initrd will be started immediately after
406booting to perform hardware autodetection (just like on the Live CD) before 411booting to perform hardware autodetection (just like on the Installation CD) before
407your "real" system starts up. 412your "real" system starts up.
408</p> 413</p>
409 414
410<pre caption="Checking the created kernel image name and initrd"> 415<pre caption="Checking the created kernel image name and initrd">
411# <i>ls /boot/kernel* /boot/initrd*</i> 416# <i>ls /boot/kernel* /boot/initramfs-*</i>
412</pre> 417</pre>
413 418
414<p> 419<p>
415Now, let's perform one more step to get our system to be more like the Live 420Now, let's perform one more step to get our system to be more like the Installation CD -- let's emerge <c>coldplug</c>. While the initrd autodetects hardware that
416CD -- let's emerge <c>coldplug</c>. While the initrd autodetects hardware that
417is needed to boot your system, <c>coldplug</c> autodetects everything else. 421is needed to boot your system, <c>coldplug</c> autodetects everything else.
418To emerge and enable <c>coldplug</c>, type the following: 422To emerge and enable <c>coldplug</c>, type the following:
419</p> 423</p>
420 424
421<pre caption="Emerging and enabling coldplug"> 425<pre caption="Emerging and enabling coldplug">
422# <i>emerge coldplug</i> 426# <i>emerge coldplug</i>
423# <i>rc-update add coldplug default</i> 427# <i>rc-update add coldplug boot</i>
424</pre> 428</pre>
425 429
426</body> 430</body>
427</section> 431</section>
428<section id="kernel_modules"> 432<section id="kernel_modules">
444 <th>Ebuild</th> 448 <th>Ebuild</th>
445 <th>Purpose</th> 449 <th>Purpose</th>
446 <th>Command</th> 450 <th>Command</th>
447</tr> 451</tr>
448<tr> 452<tr>
449 <ti>xfree-drm (or x11-drm)</ti> 453 <ti>x11-drm</ti>
450 <ti> 454 <ti>
451 Accelerated graphics for ATI Radeon up to 9200, Rage128, Matrox, Voodoo and 455 Accelerated graphics for ATI Radeon up to 9200, Rage128, Matrox, Voodoo and
452 other cards for XFree86. Please check the <c>IUSE_VIDEO_CARDS</c> variable 456 other cards for xorg-x11. Please check the <c>IUSE_VIDEO_CARDS</c> variable
453 in the <path>/usr/portage/x11-base/xfree-drm</path> ebuilds to see what you 457 in the <path>/usr/portage/x11-base/x11-drm</path> ebuilds to see what you
454 need to fill in as <c>yourcard</c>. The xfree-drm ebuild has been renamed to 458 need to fill in as <c>yourcard</c>.
455 x11-drm after the 2004.3 release.
456 </ti> 459 </ti>
457 <ti><c>VIDEO_CARDS="yourcard" emerge xfree-drm</c></ti> 460 <ti><c>VIDEO_CARDS="yourcard" emerge x11-drm</c></ti>
458</tr> 461</tr>
459</table> 462</table>
460 463
461<p> 464<p>
462Beware though, some of these ebuilds might deal with big dependencies. To verify 465Beware though, some of these ebuilds might deal with big dependencies. To verify
463what packages will be installed by emerging an ebuild, use <c>emerge 466what packages will be installed by emerging an ebuild, use <c>emerge
464--pretend</c>. For instance, for the <c>xfree-drm</c> package: 467--pretend</c>. For instance, for the <c>x11-drm</c> package:
465</p> 468</p>
466 469
467<pre caption="View full installation package listing"> 470<pre caption="View full installation package listing">
468# <i>emerge --pretend xfree-drm</i> 471# <i>emerge --pretend x11-drm</i>
469</pre> 472</pre>
470 473
471</body> 474</body>
472</subsection> 475</subsection>
473<subsection> 476<subsection>
504<pre caption="/etc/modules.autoload.d/kernel-2.4 or kernel-2.6"> 507<pre caption="/etc/modules.autoload.d/kernel-2.4 or kernel-2.6">
5053c59x 5083c59x
506</pre> 509</pre>
507 510
508<p> 511<p>
509Now run <c>modules-update</c> to commit your changes to the
510<path>/etc/modules.conf</path> file:
511</p>
512
513<pre caption="Running modules-update">
514# <i>modules-update</i>
515</pre>
516
517<p>
518Continue the installation with <uri link="?part=1&amp;chap=8">Configuring 512Continue the installation with <uri link="?part=1&amp;chap=8">Configuring
519your System</uri>. 513your System</uri>.
520</p> 514</p>
521 515
522</body> 516</body>

Legend:
Removed from v.1.15  
changed lines
  Added in v.1.30

  ViewVC Help
Powered by ViewVC 1.1.20