LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 09-22-2009, 07:51 PM   #1
bskumar7080
Member
 
Registered: Aug 2009
Distribution: Mandriva
Posts: 57

Rep: Reputation: 15
Steps to compile and configure kernel


Hi all,
I am using ubuntu distribution, I like to update my kernel , my present version kernel is 2.6.28-11-generic #42-Ubuntu SMP Fri Apr 17 01:57:59 UTC 2009 i686 GNU/Linux.
i downloaded latest kernel source from kernel.org "linux-2.6.31.tar.bz2" i followed the following steps to configure my kernel

1. i extracted the kernel source file in usr/src
2. I updated my gcc complier

root@sivakumar-desktop:/usr/src# apt-get install gcc
Reading package lists... Done
Building dependency tree
Reading state information... Done
gcc is already the newest version.
0 upgraded, 0 newly installed, 0 to remove and 228 not upgraded.

3. Then i tried to run make menuconfig, i got the following error

root@sivakumar-desktop:/usr/src# make menuconfig
make: *** No rule to make target `menuconfig'. Stop.

4. then i tried

root@sivakumar-desktop:/usr/src/linux-2.6.31# make menuconfig
*** Unable to find the ncurses libraries or the
*** required header files.
*** 'make menuconfig' requires the ncurses libraries.
***
*** Install ncurses (ncurses-devel) and try again.
***
make[1]: *** [scripts/kconfig/dochecklxdialog] Error 1
make: *** [menuconfig] Error 2
 
Old 09-22-2009, 07:58 PM   #2
GlennsPref
Senior Member
 
Registered: Apr 2004
Location: Brisbane, Australia
Distribution: Devuan
Posts: 3,657
Blog Entries: 33

Rep: Reputation: 283Reputation: 283Reputation: 283
Hi, what that means is you need to install the ncurses-dev package, but if you run make xconfig it may work without it.

You may also need libqt3-dev.

What I would do first is to run make oldconfig.

That will preserve settings from the working kernel and any ubunto enhancements.

Then run the config.

and save it, then run

make all

make modules_install

su to root and run

make install.

Cheers, Glenn
 
Old 09-22-2009, 09:36 PM   #3
bskumar7080
Member
 
Registered: Aug 2009
Distribution: Mandriva
Posts: 57

Original Poster
Rep: Reputation: 15
Steps after this

root@sivakumar-desktop:/usr/src/linux-2.6.31# make install
sh /usr/src/linux-2.6.31/arch/x86/boot/install.sh 2.6.31 arch/x86/boot/bzImage \
System.map "/boot"
root@sivakumar-desktop:/usr/src/linux-2.6.31#
 
Old 09-22-2009, 09:39 PM   #4
bskumar7080
Member
 
Registered: Aug 2009
Distribution: Mandriva
Posts: 57

Original Poster
Rep: Reputation: 15
when i run make install, i get the following message

root@sivakumar-desktop:/usr/src/linux-2.6.31# make install
sh /usr/src/linux-2.6.31/arch/x86/boot/install.sh 2.6.31 arch/x86/boot/bzImage \
System.map "/boot"
root@sivakumar-desktop:/usr/src/linux-2.6.31#
 
Old 09-22-2009, 10:18 PM   #5
~sHyLoCk~
Senior Member
 
Registered: Jul 2008
Location: /dev/null
Posts: 1,173
Blog Entries: 12

Rep: Reputation: 129Reputation: 129
Type:
Code:
ls /boot
 
Old 09-22-2009, 10:29 PM   #6
bskumar7080
Member
 
Registered: Aug 2009
Distribution: Mandriva
Posts: 57

Original Poster
Rep: Reputation: 15
when ityped ls /boot i got the following output

root@sivakumar-desktop:/# ls /boot
abi-2.6.28-11-generic grub System.map-2.6.28-11-generic vmlinuz-2.6.28-11-generic
config-2.6.28-11-generic initrd.img-2.6.28-11-generic System.map-2.6.31 vmlinuz-2.6.31
config-2.6.31 lost+found System.map-2.6.31.old vmlinuz-2.6.31.old
config-2.6.31.old memtest86+.bin vmcoreinfo-2.6.28-11-generic
 
Old 09-22-2009, 11:14 PM   #7
el_b
Member
 
Registered: Apr 2009
Distribution: Slackware 13.0
Posts: 48

Rep: Reputation: 17
If you're using a debain-based system such as ubuntu, l. mint, debian, etc, use make_kpkg... Just google it.
 
Old 09-23-2009, 03:48 AM   #8
GlennsPref
Senior Member
 
Registered: Apr 2004
Location: Brisbane, Australia
Distribution: Devuan
Posts: 3,657
Blog Entries: 33

Rep: Reputation: 283Reputation: 283Reputation: 283
Smile No errors = good news.

Quote:
Originally Posted by bskumar7080 View Post
when i run make install, i get the following message

root@sivakumar-desktop:/usr/src/linux-2.6.31# make install
sh /usr/src/linux-2.6.31/arch/x86/boot/install.sh 2.6.31 arch/x86/boot/bzImage \
System.map "/boot"
root@sivakumar-desktop:/usr/src/linux-2.6.31#
Hi, no error messages, Just a statement, all is good, reboot and select the 2.6.31 kernel to test.

Regards Glenn
 
Old 09-23-2009, 05:00 AM   #9
~sHyLoCk~
Senior Member
 
Registered: Jul 2008
Location: /dev/null
Posts: 1,173
Blog Entries: 12

Rep: Reputation: 129Reputation: 129
Quote:
Originally Posted by bskumar7080 View Post
when ityped ls /boot i got the following output

root@sivakumar-desktop:/# ls /boot
abi-2.6.28-11-generic grub System.map-2.6.28-11-generic vmlinuz-2.6.28-11-generic
config-2.6.28-11-generic initrd.img-2.6.28-11-generic System.map-2.6.31 vmlinuz-2.6.31
config-2.6.31 lost+found System.map-2.6.31.old vmlinuz-2.6.31.old
config-2.6.31.old memtest86+.bin vmcoreinfo-2.6.28-11-generic
Did you make changes to grub and added the new kernel?
 
Old 09-23-2009, 06:51 AM   #10
bskumar7080
Member
 
Registered: Aug 2009
Distribution: Mandriva
Posts: 57

Original Poster
Rep: Reputation: 15
I restarted and updated the grup, in the boot screen there was two options to select for the kernel 2.6.28 and kernel 2.6.31. iselected first kernel 2.6.31 i got the following message,

[2.612091] kernel panic not syncing : UFS : Unable to mount root s on unknown block (6,0)

Then two leds (caps lock and scroll led) continues to blink in keyboard,

Then when i restart and selected kernel 2.6.28. it asks my username and password after that i got error message as
"An error occurs while loading or saving configuration for update notifier"
"an error occurs while loading graphical....etc"

i was able to boot in text mode kernel 2.6.28
 
Old 09-23-2009, 06:52 AM   #11
bskumar7080
Member
 
Registered: Aug 2009
Distribution: Mandriva
Posts: 57

Original Poster
Rep: Reputation: 15
I restarted and updated the grup, in the boot screen there was two options to select for the kernel 2.6.28 and kernel 2.6.31. iselected first kernel 2.6.31 i got the following message,

[2.612091] kernel panic not syncing : UFS : Unable to mount root s on unknown block (6,0)

Then two leds (caps lock and scroll led) continues to blink in keyboard,

Then when i restart and selected kernel 2.6.28. it asks my username and password after that i got error message as
"An error occurs while loading or saving configuration for update notifier"
"an error occurs while loading graphical....etc"

i was able to boot in text mode kernel 2.6.28
 
  


Reply



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
Someone knows to configure & compile a 2.4.35.x kernel? zoby Slackware 15 11-29-2007 10:24 AM
How to configure & compile a 2.4.35.x kernel? zoby LinuxQuestions.org Member Intro 1 11-26-2007 02:20 AM
configure and compile own kernel Keruskerfuerst SUSE / openSUSE 8 11-16-2005 06:17 AM
So what are the steps to compile 2.6.0? CodeWarrior Slackware 15 12-25-2003 11:25 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 04:56 AM.

Main Menu
Advertisement
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
Open Source Consulting | Domain Registration