LinuxQuestions.org
Visit the LQ Articles and Editorials section
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Mandriva
User Name
Password
Mandriva This Forum is for the discussion of Mandriva (Mandrake) Linux.

Notices

Reply
 
Search this Thread
Old 01-02-2005, 01:01 AM   #1
rksprst
Member
 
Registered: Jan 2004
Distribution: OS X 10.4
Posts: 172
Blog Entries: 1

Rep: Reputation: 30
recompile kernel


ok so i found this article about recompiling the kernel in mandrake
http://pgshopping.com/mdkxp/?c=ttrls/mdkkernel

now i have a question, i have the following folders in the /usr/src section
Quote:
[root@linux src]# cd /usr/src/
[root@linux src]# ls
linux@ linux-2.4.27-0.pre2.1mdk/ linux-2.6.8.1-10mdk/ RPM/
[root@linux src]#
which version do i use?

right now i think im supposed to use the linux-2.6 one?


my first time doing anything this drastic in linux..hope i dont mess up

Edit:
i forgot, umm... do i need to install some programs for to compile?
a c++ compiler or something similar?
and how do i know if this is already installed?

Last edited by rksprst; 01-02-2005 at 01:09 AM.
 
Old 01-02-2005, 01:16 AM   #2
davcefai
Member
 
Registered: Dec 2004
Location: Malta
Distribution: Debian Sid
Posts: 764

Rep: Reputation: 32
Recompiling the Kernel

First of all: This is not a full answer.

You should have a directory /usr/source/linux which is really a link to the most recently installed source. In File Manager, examine its properties. It should point to linux-2.6.8.1-10mdk. You work in the linux directory not the linux-2.6.8.1-10mdk one. If this is not so, do not proceed!

Next, go to http://linuxreviews.org/howtos/Kerne...GURATION-INTRO where the whole process is very well explained.

I would suggest you use the make xconfig option - it is the most convenient one to use.

Remember that, after you compile you need to add the new kernel to your boot loader menu and you will still have the old one available so that if something goes wrong you will still be able to boot the old kernel.

I've done this only once before and am preparing to do it again soon so I'm not in a position to give you detailed help, only pointers and encouragement!

Good luck
 
Old 01-02-2005, 01:32 AM   #3
rksprst
Member
 
Registered: Jan 2004
Distribution: OS X 10.4
Posts: 172
Blog Entries: 1

Original Poster
Rep: Reputation: 30
Thanks,

I went to the link and read it.
Im following the tutorial at the link i posted now.
The tutorial explains how to change grub to use the new kernel.

And i just rmmred that I installed the compiling packages back when i installed mandrake.

Hope i dont mess up
 
Old 01-02-2005, 02:40 AM   #4
GlennsPref
Senior Member
 
Registered: Apr 2004
Location: Brisbane, Australia
Distribution: Mageia Studio-13.37 Kubuntu.
Posts: 3,325
Blog Entries: 33

Rep: Reputation: 199Reputation: 199
2.6.x series

o Gnu C 2.95.3 # gcc --version
o Gnu make 3.78 # make --version
o binutils 2.12 # ld -v
o util-linux 2.10o # fdformat --version
o module-init-tools 0.9.10 # depmod -V
o e2fsprogs 1.29 # tune2fs
o jfsutils 1.1.3 # fsck.jfs -V
o reiserfsprogs 3.6.3 # reiserfsck -V 2>&1|grep reiserfsprogs
o xfsprogs 2.1.0 # xfs_db -V
o pcmcia-cs 3.1.21 # cardmgr -V
o quota-tools 3.09 # quota -V
o PPP 2.4.0 # pppd --version
o isdn4k-utils 3.1pre1 # isdnctrl 2>&1|grep version
o nfs-utils 1.0.5 # showmount --version
o procps 3.1.13 # ps --version
o oprofile 0.5.3 # oprofiled --version

2.6 has more features than the 2.4, but keep the 2.4 as a fall-back, incase it won't boot first time.
 
Old 01-02-2005, 05:48 AM   #5
rksprst
Member
 
Registered: Jan 2004
Distribution: OS X 10.4
Posts: 172
Blog Entries: 1

Original Poster
Rep: Reputation: 30
Talking

I did it. It works perfectly.
I edited the .config file and now my ipod works with gnupod
 
Old 01-02-2005, 07:15 AM   #6
davcefai
Member
 
Registered: Dec 2004
Location: Malta
Distribution: Debian Sid
Posts: 764

Rep: Reputation: 32
Kernel Compilation

The sad thing is that, after replying to your post, I decided to compile mine. (It's a cold. rainy day outside).

However my new kernel won't boot! (Panic, unable to mount root filesystem).

I haven't taken the time to have a good look but I might be posting queries here shortly!
 
Old 01-02-2005, 07:31 AM   #7
rksprst
Member
 
Registered: Jan 2004
Distribution: OS X 10.4
Posts: 172
Blog Entries: 1

Original Poster
Rep: Reputation: 30
Just a thought, did you do mkinitrd /boot/initrd-2.4.19-1custom.img 2.4.19-1custom ?

Look at /boot/ maybe there is a file missing there? This is mine. (everything with custom, is the new kernel that i just installed)
Quote:
[alex@linux boot]$ ls
boot.0300
config@
config-2.6.8.1-10custom
config-2.6.8.1-10mdk
diag1.img
diag2.img
grub/
initrd-2.6.8.1-10custom.img
initrd-2.6.8.1-10mdk.img
initrd.img@
kernel.h@
kernel.h-2.6.8.1-10mdk
kernel.h-2.6.8-1custom
map
message@
message-graphic
message-text
System.map@
System.map-2.6.8.1-10custom
System.map-2.6.8.1-10mdk
us.klt
vmlinuz@
vmlinuz-2.6.8.1-10custom
vmlinuz-2.6.8.1-10mdk
[alex@linux boot]$
 
Old 01-02-2005, 09:18 AM   #8
wongster
LQ Newbie
 
Registered: Nov 2004
Posts: 17

Rep: Reputation: 0
Hi,

Great to hear about your success in recompiling the 2.6 kernel.

I was trying to reconfigure using xconfig but there is an error message saying that I need to install QT. Searched thru my Mandrake 10.1 official CDs turn out nothing.

Can you advise?

How would I name the newly configured and recompiled kernel to another name, say 2.6XX.custom, like what you did?

When everything works as it should, how can I get rid of the old kernel completely to save space?


Sorry for the many questions. Hope you can help.

Thanks.

Wongster
 
Old 01-02-2005, 10:28 AM   #9
davcefai
Member
 
Registered: Dec 2004
Location: Malta
Distribution: Debian Sid
Posts: 764

Rep: Reputation: 32
Wongster:

What you have to install are all the libqt* bits, there are no "QT" entries.

You should find a few files starting with "libqt". Install those.

Rkprst:

I think I may have made a mistake in configuration. What I get on booting is:

UDF-fs: No Partition found
Kernel panic: VFS: unable to mount root fs on hdf1

I am interpreting this as meaning that instead of an ext2 system, linux is expecting a UDF one.

The weird thing is that my new System.map-2.6.3-19mdk file vanishes and and System.map points back to the old map file.
 
Old 01-02-2005, 02:05 PM   #10
rksprst
Member
 
Registered: Jan 2004
Distribution: OS X 10.4
Posts: 172
Blog Entries: 1

Original Poster
Rep: Reputation: 30
Wongster:
I don't know how to rename it after you compiled it. But If you check out this link: http://pgshopping.com/mdkxp/?c=ttrls/mdkkernel it really explains everything step by step and thats the tutorial i used to compile the kernel.
what I did was basically copy the kernel and rename it: cp -a linux-2.6.8.1-10mdk linux-2.6.8.1-10custom i did this before compiling

about the QT error, try installing all the developmental packages that come with ur distro.
I think these are some, but not all of the packages you need:
Quote:
> libqt-dev - Qt GUI development files
> libqt-mt-dev - Qt GUI development files (Threaded version)
> libqte-mt3-dev - Qt/Embedded GUI (Threaded Version) development files
> libqwt-dev - Qt widgets library for technical applications (development)
> libqt3-dev - Qt development files
> libqt3-mt-dev - Qt development files (Threaded)

Davcefai:
Check out this article, the person had the same error as you.
http://www.linuxquestions.org/questi...hreadid=159649
the user says this about the error:
Quote:
Regarding the error in booting from your new 2.6 kernel: you probably failed to compile support for ReiserFS, the default filesystem for Slackware (or support for whatever filesystem you use). So, when you boot the new kernel, it can't mount your /boot partition and panics.
Hope this helps
-alex
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
how to recompile kernel 2.4.21-15.EL zameer_india Linux - Newbie 2 12-24-2004 01:02 AM
kernel recompile error (kernel panic) tombaaaaa Linux - Newbie 4 08-04-2004 04:32 PM
Recompile kernel 2.6 heema Linux - General 3 05-26-2004 10:29 AM
9.2 kernel recompile dukeinlondon Mandriva 3 11-10-2003 06:34 AM
Recompile Kernel ? Amerist Linux - Newbie 5 04-16-2002 04:13 AM


All times are GMT -5. The time now is 02:06 PM.

Main Menu
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration