cvs commit: hints kernel-2_6-migration.txt
tushar at linuxfromscratch.org
tushar at linuxfromscratch.org
Tue Dec 23 15:45:52 PST 2003
tushar 03/12/23 16:45:52
Modified: . kernel-2_6-migration.txt
Revision Changes Path
1.3 +141 -40 hints/kernel-2_6-migration.txt
RCS file: /home/cvsroot/hints/kernel-2_6-migration.txt,v
retrieving revision 1.2
retrieving revision 1.3
diff -u -u -r1.2 -r1.3
--- kernel-2_6-migration.txt 20 Dec 2003 19:14:57 -0000 1.2
+++ kernel-2_6-migration.txt 23 Dec 2003 23:45:52 -0000 1.3
@@ -1,7 +1,6 @@
-AUTHOR: Kris van Rens
- kvrprogs AT edsko DOT com
+AUTHOR: Kris van Rens <kvrprogs AT edsko DOT com>
@@ -10,17 +9,17 @@
After a series of 11 test versions, the stable release of the linux-2.6 kernel
-came out (linux-2.6.0), one day before I wrote this hint. I was working with
-the 2.6.0test kernel a few months already for school (for the curious among
-you; I learn how to design kernel driver modules). I noticed a few people on
-the mailinglist having trouble installing the kernel, that's what made me write
+came out (linux-2.6.0), on december the 18th 2003. I was working with the
+2.6.0test kernel a few months already for school (for the curious among you; I
+learn how to design kernel driver modules). I noticed a few people on the
+mailinglist having trouble installing the kernel, that's what made me write
So, if you're one of the people wanting to try out the new 2.6.0 kernel, you
should probably take a look at this hint for a few tips to bring it to a
-successful end. Of course the new kernel does not have to better for you, you
-might have some trouble with NVIDIA-drivers or winmodems. You can always fall
-back to the 2.4 kernel and wait a while before you'll try it again.
+successful end. Of course the new kernel does not have to be better for you,
+you might have some trouble with NVIDIA-drivers or winmodems. You can always
+fall back to the 2.4 kernel and wait a while before you'll try it again.
@@ -31,7 +30,7 @@
Get this from http://www.kernel.org/pub/linux/kernel/people/rusty/modules.
*** linux-2.6.x kernel sources tarball
-Get these from http://www.kernel.org or a mirror.
+Get this from http://www.kernel.org or a mirror.
At the time of writing the version of the module-init-tools is 0.9.15-pre4 and
for the kernel it is 2.6.0, I'll use these version names for this hint, if you
@@ -40,6 +39,18 @@
Of course, you should also have Make, GCC and an Assembler, but this hint is
meant for the LFS-community so I'll assume you fulfill these requirements.
+You might also want to fullfil the recommendations of the kernel development
+team and use GCC-2.95.3 for kernel compilation, you can download it here:
+ftp://ftp.gnu.org/gnu/gcc/gcc-2.95.3.tar.gz or from a mirror.
+Read the /usr/src/linux-2.6.0/Documentation/Changes document for other programs
+you'll eventually need to update. For LFS-5.0 you should for example also
+Note that there is a much better readable HTML version of this hint on my
+website, check the bottom of this hint for the URL.
@@ -48,8 +59,8 @@
multiple processor cores) and the uniprocessor power increased, compatibility
with hardware is better and new security-modules increase the security (!).
-As being the owner of a LFS system, I'll assume you're familiar with the usual
-way of installing a source package, and a kernel of course.
+Being the owner of a LFS system, I'll assume you're familiar with the usual way
+of installing a source package, and a kernel of course.
I cut this hint section in two; installing the new module-init-tools and
installing the kernel.
@@ -58,7 +69,7 @@
you want to be sure that you don't have to undertake special steps, take a
look at the EXCEPTIONS area. It's always a good idea to take a look there.
-***STEP 1: Obtaining and installing the new module-init-tools
+***STEP 1: Installing the new module-init-tools
To migrate from kernel 2.4 to 2.6 you'll need a new module loading system, the
system has been worked over completely.
@@ -97,12 +108,13 @@
-The last thing you'll have to do is to generate a new configurationfile for the
+The last thing you'll have to do is to generate a new configuration file for
-If you're using the device-filesystem also copy the modprobe.devfs into /etc.
+If you're using the device-filesystem also copy the modprobe.devfs file into
If everything went fine, you have the new module-init-tools and you're ready to
install the new kernel!
@@ -116,35 +128,75 @@
tar xjf linux-2.6.0.tar.bz2
+If you want to install the kernel version tarball without patching, you can
+skip the tabulated field down here, read it if you want to patch the kernel.
+ If you want to install the kernel with patches, say you have
+ linux-2.6.0test9 and you want to install linux-2.6.0, you'll need the
+ patches linux-2.6.0test10.patch, linux-2.6.0test11.patch and
+ Now go to the root of the kernel source tree and patch the kernel in the
+ correct order (cumulative patching). Adapt the patch name for your
+ patch -p1 < ../linux-2.6.0test10.patch
+ patch -p1 < ../linux-2.6.0test11.patch
+ patch -p1 < ../linux-2.6.0.patch
+ Read the 'README' file in the root of the kernel source tree for more info
+ on how to patch a kernel.
Now configure the kernel, this is just like with the 2.4 kernel, you can choose
-from menuconfig and xconfig. Menuconfig is based on Ncurses and xconfig is
-based on QT. Do so by:
+from menuconfig, xconfig and gconfig. Menuconfig is based on Ncurses, xconfig
+is based on QT and gconfig is based on GTK+, for the last two, you'll need X to
+run. Do so by:
-Now comes the most time-spending and difficult part, the configuration itself.
+Now comes the most time-consuming and difficult part, the configuration itself.
As far as I know, you cannot use the kernel-2.4 configuration file. So you'll
have to do it all from the start, which is better anyway, because a lot changed
in the structure of the menu and there are loads of new options in it.
-Be sure to take the right systemarchitecture in >>processor-type and features<<
+Be sure to take the right system architecture in >>processor-type and features<<
and the right filesystem. If you don't know whether you should involve a
certain option or not, press ? or help; there's info about almost every option.
If you still don't know, search or ask the community.
-If you're done, you are set to compile the kernel with:
+If you're done, you are set to compile the kernel.
+The kernel developement team recommends you to build the kernel with GCC-2.95.3
+it is not a must, but stability is not guaranteed if you deviate from this
+version. I tried both GCC-3.3.1 and GCC-2.95.3, they both worked fine for me.
+You can choose which compiler to use if you change the CC flag for make.
+To make the kernel with your global GCC version, which is GCC-3.3.1 for
-This can take quite a while, on my Pentium 4 2.0GHz with 256MB RAM, it took
-about 15 minutes, which is not strange because the kernel code is around 5
-million lines of code! You can time your build with >>time make all<< instead.
+To make the kernel with GCC-2.95.3 (situated in /opt/gcc-2.95.3 according to
+the LFS-book) do:
-Then install the modules with:
+make CC=/opt/gcc-2.95.3/bin/gcc all
+This can take quite a while, on my Pentium 4 2.0GHz with 256MB RAM, it took
+about 11 minutes, which is not strange because the kernel code is around 5
+million lines of code! You can time your build with >>time make all<<
+respectively >>time make CC=/bin/gcc-2.95.3/bin/gcc all<< instead.
+We are now going to install the modules, you don't have to use the CC flag
+anymore, since the modules were compiled at the end of 'make all', you must
+install them with:
@@ -154,26 +206,43 @@
Or to another filename as you want.
+The versioning is supported on 'System.map', you'll have to copy this file to
+your /boot directory. Before you do so, consider keeping the 2.4-System.map;
+you can rename it to 'System.map-2.4.22' (for kernel-2.4.22 of course) and the
+new 2.6 one to 'System.map-2.6.0' so that each kernel version gets it's own.
Now modify your lilo.conf (for lilo) of menu.lst (for grub) to be able to load
the new kernel, if you have lilo, don't forget to invoke /sbin/lilo and re-
write the boot-record.
-If everything went right, you can reboot and start with the new kernel.
+You should look at the EXCEPTIONS field, you might have to do some additional
+work to get your kernel function properly.
+If everything is done, you can reboot and start with the new kernel.
+If there were problems during booting, check the TROUBLESHOOTING section,
+otherwise, congratulations with you're shiny new 2.6 kernel!
If there are errors during the booting, read the error-output carefully and
-eventually reconfigure the kernel. Otherwise if your screen is black, it has
-probably something to do with the framebuffer device, also reconfigure the
-kernel and try again. Or try vga=normal in your bootloader configuration, and
-check if 'CONFIG_VT' is set to 'y' in your .config file.
+eventually reconfigure the kernel. Here are listed a few common problems and
+some possible answers. You should also check the EXCEPTIONS section.
-You should look at the EXCEPTIONS field, you might have to do some additional
-work to get your kernel work properly.
+---Your screen is black during booting
+This has probably something to do with the framebuffer device, try vga=normal
+in your bootloader configuration, and check if 'CONFIG_VT' is set to 'y' in
+your .config (kernel configuration) file.
+---The module loading system complains about wrong module versions
+You probably forgot to run >>make modules_install<< make sure that the
+modules on which you run >>make modules_install<< are compiled with the same
+version as the kernel itself.
If the problem is really stubborn and you can't get it away, read the
mailinglist archives or ask a new question there.
-Otherwise, congratulations with you're shiny new 2.6 kernel!
@@ -200,19 +269,32 @@
OTHER DOCUMENTS ABOUT THIS SUBJECT:
-The post-halloween document from Dave Jones:
+---The HTML version of this hint! (much more readable):
+---The post-halloween document from Dave Jones:
-The German translation of it:
+Or if this doesn't work:
+---The German translation of post-halloween:
+---Another migration hint:
Professor Dr. Juergen Quade from the Niederrein University for printing me
- out the preleminary version of the 'Meister-Installateur' article for
+ out the preliminary version of the 'Meister-Installateur' article for
the Linux Magazin.
+The BLFS-Support mailling list and its members, for pointing me at weak spots
+ in the hint. Thanks!
@@ -221,5 +303,24 @@
*Changed DATE format to intl.
- *Structural fixes + some typos
+ *Structural fixes + some typos; thanks Matthew!
*Added the EXCEPTIONS field; thanks Alexander!
+ Version 1.2
+ *Added gcc-2.95 into kernel build
+ *Added new url
+ *Made the hint idiot proof ;-) thanks to Declan!
+ Version 1.3
+ *Added new url
+ *Added kernel patching
+ *Added System.map stuff
+ *Added the TROUBLESHOOTING section
+ *Added/changed several comments in all sections.
+ Version 1.4
+ *Fixed a few typos
+ Version 1.5
+ *Changed a few sentences and corrected some typos
+ *Added a reference to the HTML version on my website
More information about the hints