Read on full site | Join TechSpot! (it's free) | Bookmark / Share this



recompile and reinstall of 2.6.x

Spike
05-26-2004, 01:32 PM
I've just got hold of Mandrake 10.0

you may remember that I gav up with MD 9.x after a series of problems, in the hope that when I got 10.0, the problems would be solved.

The trouble is, in order to install the required drivr for my DSL modem, I need to run a patch (which I have instructions for), but then I need to recompile and install my kernel.

Is this process the same as in the kernel installation thread (at which I failed miserably many times!), or is there an easier way of doing it. Is there anything I should miss out? Each time I tried to upgrade from 2.4.x to 2.6.x under MD 9.2, it left my linux unbootable.

Phantasm66
05-26-2004, 02:37 PM
Its not hard to compile your own kernel if you know a few things.

First of all, try downloading the 2.6.6 kernel from www.kernel.org

uncompress it with this command:

tar -zxvf linux-2.6.6.tar.gz (filename may differ)

then,

make mrproper
make clean
make xconfig

when the xconfig tool appears, load the attached myconfig file in.

then save, close tool.

now,

make

then

make modules

then

make modules_install

then go into ./arch/i386/boot

copy bzImage file to /boot

rename to mykernel or something like that.

make an initrd file

mkinitrd /boot/initrd-2.6.6.img 2.6.6

then edit your /etc/grub.conf file, so that you add lines for your new kernel like this:

title My New 2.6.6 kernel
root (hd0,0)
kernel /boot/kernel-2.6.6 ro root=/dev/hda
initrd /boot/initrd-2.6.6.img


There's probably something already in /etc/grub.conf so just copy that. You don't need to reinstall grub when you make changes to /etc/grub.conf

I think there is everything you need.

Ad
05-26-2004, 02:37 PM
  

Phantasm66
05-26-2004, 02:41 PM
here's the file you should use to config your kernel, basically its just a hack of mine of the default i686 kernel config you get with fedora core. It should work fine. I think I did it for an Athlon though so if you have anything else you should change it under processor type section.

Leave anything old still in /etc/grub.conf and don't remove your old kernel.

Spike
05-26-2004, 10:02 PM
Thankyou for that. I've extracted the source to /usr/src, but I can't seem to go any further with your instructions, see screenshot below...

http://www.IMGSpot.com/u/04/147/02/krnlcomp.jpg

I also can't patch the source anyway, from the instructions, see image (again, below)...



http://www.IMGSpot.com/u/04/147/02/modempatch.jpeg

I really would like to get this sorted now. I've waited a while to try Linux again, and maybe learn something about using it, but if it won't work for me, there's not much hope really. I guess I'm missing something?

Didou
05-27-2004, 04:21 AM
This should work ->

[root@armilia david]# cd /usr/src/
[root@armilia src]# tar xvfj linux-2.6.6.tar.bz2
[root@armilia src]# ln -s linux-2.6.6 linux-2.6
[root@armiliasrc ]# ln -s linux-2.6.6 linux
[root@armilia src]# patch -p1 </mnt/windows/2.6.x-usb.patch
[root@armilia linux]# cd linux
[root@armilia linux]# make mrproper
[root@armilia linux]# make menuconfig
[root@armilia linux]# make && make modules && make modules_install && make install

PS. the parameter for patch is -p1, you seem to put -pl.

Spike
05-27-2004, 07:10 AM
Thanks for that Didou. Certainly a step in the right direction. I can patch the source now. A classic case of Error Between Chair and Keyboard I think :D

However, I've encountered the following error...

http://www.IMGSpot.com/u/04/147/11/2ndattempt.jpg

Is it important, and any idea what I should do if it is?

Didou
05-27-2004, 07:30 AM
It will be quite hard to re-compile anything ( let alone the Linux kernel ) without GCC.;)

Try ->

[root@armilia root]# urpmi gcc

Then proceed back to the make mrproper part.:)

Spike
05-27-2004, 08:58 PM
Many thanks. 2.6.6 now patched, compiled, and installed :D

Phantasm66
05-28-2004, 05:36 AM
If you are following what I said from above, make sure that you actually perform the make operations inside the directory you extracted and not its parent directory (i.e. you were trying to do this in /usr/src, not /usr/src/linux-2.6/)


When you install Linux, try to do a full install and certainly take all of the development stuff - you need gcc and the other bits and pops to do things in Linux. Linux is open source so you need to be able to build applications, kernels, drivers and other things from source code.

Spike
05-28-2004, 08:17 AM
thanks for the advice/explanation P66. I will bear that in mind. Thankyou very much for your help both. I've now installed the development stuff. If I can just sort my modem out, I'll be a happy bunny. lol :D

Ad
05-28-2004, 08:17 AM
  

Phantasm66
05-28-2004, 09:37 AM
Keep plugging away, that's how you'll learn. If you've already built and installed your own kernel then you are well on your way.

Post a reply, see related topics & more

Tip: Download Advanced SystemCare 3 Free - Clean, Repair, Protect & Optimize your PC.



 Top Technology News

TechSpot Blog: Disable Windows automatic check for solutions after a program crashes

Weekend Open Forum: Google Chrome OS and the future of cloud computing

Tech Tip of the Week: Unearth Region-Specific Windows 7 Themes

Weekend tech reading: How to run Chrome OS as a virtual machine

Sony: PlayStation 3 to be 3D-capable via firmware update

iSuppli: DDR3 to account for over half of DRAM shipments by Q2 2010

Facebook named third most popular video website behind YouTube and Hulu

Patriot introduces new PS-100 SSD series

More Tech News

  
 Software Downloads

Norton Virus Definitions 2003-07 November 20, 2009

AVG Anti-Virus Updates November 20, 2009

Norton Virus Definitions 2008-09 November 20, 2009

avast! Virus Definitions November 20, 2009

McAfee SuperDAT Update 5808

Kaspersky Anti-Virus Update November 20, 2009

Google SketchUp 7.1.6087

More Downloads



Copyright © 1998-2009 TechSpot.com. TechSpot is a registered trademark. All Rights Reserved.