LinuxQuestions.org
View the Most Wanted LQ Wiki articles.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices

Reply
 
Search this Thread
Old 08-16-2005, 07:06 AM   #1
b0nd
Senior Member
 
Registered: Jan 2005
Distribution: Slackware, BackTrack, Windows XP
Posts: 1,020

Rep: Reputation: 45
kernel compilation-From where it should be started for already compiled kernel


Hello all,
I compiled Redhat 9.
Being a newbie i made small changes only.
Since it has been compiled perfectly...so i would like to move a step further.
When i was compiling for the first time, i reloaded the old
Code:
/boot/config-2.4.20-8
i gave the name to new kernel as kernel-2.4.2016.
but i'm not getting any file with the name /boot/.....( path to the folder in which all relevent files are..../config-2.4.2016

so what should i reload now ????
reloading config-2.4.20-8 will roll back the newly compiled kernel to the original one ( i suppose ).

regards
 
Old 08-16-2005, 07:14 AM   #2
b0nd
Senior Member
 
Registered: Jan 2005
Distribution: Slackware, BackTrack, Windows XP
Posts: 1,020

Original Poster
Rep: Reputation: 45
or should it be this one
/usr/scr/linux( my extracted folder of the source )/.config
 
Old 08-16-2005, 11:20 AM   #3
Vgui
Member
 
Registered: Apr 2005
Location: Canada
Distribution: Slackware
Posts: 496

Rep: Reputation: 31
Instead of using make menuconfig (or xconfig if you are a GUI person), you can do make oldconfig which will work from your previous .config file (if it is in the correct location).
 
Old 08-16-2005, 01:04 PM   #4
masand
Guru
 
Registered: May 2003
Location: INDIA
Distribution: Ubuntu, Solaris,CentOS
Posts: 5,522

Rep: Reputation: 58
for each compilation save ur configuratin with a different name and if that works fine u can start with the last saved configuration and make changes to that

regards
 
Old 08-16-2005, 01:23 PM   #5
b0nd
Senior Member
 
Registered: Jan 2005
Distribution: Slackware, BackTrack, Windows XP
Posts: 1,020

Original Poster
Rep: Reputation: 45
hi there,
Ya i'm saving the confiugration with new name.
But how should i start with the last saved configurtion????
Which file should i reload after doing
make xconfig

regards
 
Old 08-16-2005, 01:57 PM   #6
masand
Guru
 
Registered: May 2003
Location: INDIA
Distribution: Ubuntu, Solaris,CentOS
Posts: 5,522

Rep: Reputation: 58
if u r satisfied with ur last kenrel and want to move ahaead and make changes in that
then load that file else u can choose any config file, load that settings and start working on it

regards
 
Old 08-16-2005, 11:48 PM   #7
b0nd
Senior Member
 
Registered: Jan 2005
Distribution: Slackware, BackTrack, Windows XP
Posts: 1,020

Original Poster
Rep: Reputation: 45
Quote:
Taken from the article of DrOzz

----------------------------
Now Comes The Fun Part~!
----------------------------
make mrproper
**"this removes the current .config and other files"**

cp /usr/src/linux-2.4.x/.config /usr/src/linux
***this is if you want to use your old config***
But there is no ".config" file in my sysytem inside the quoted directories

what should i do now...???

regards
 
Old 08-17-2005, 12:00 AM   #8
b0nd
Senior Member
 
Registered: Jan 2005
Distribution: Slackware, BackTrack, Windows XP
Posts: 1,020

Original Poster
Rep: Reputation: 45
HI,
just searched this article on google........

Quote:
I'm assuming here that the reader is capable of the basics in kernel
compiling, and is using something fairly compatible with my RedHat 2.4.3
kernel. Also, the ability to use X on the machine will help.

1) First step: make xconfig and once it's up, "Store Configuration
To File". Trust me, you want to do this, because your next step will
(or has in my experiences) wipe out your configuration settings, and
this will stop you from having to go back through and completely redo
your config. Quit make xconfig.
2) "make mrproper". Some of us (and I'd suspect, many of us) tend
to skip this step, possibly with the logic "I haven't changed much, so I
should just be able to start make dep ... " etc. Well, depending on
what you change, skipping this can cause your kernel compile to fail.
Near as I can tell (and I'm no expert), this is pretty much like a "make
very_clean".
3) Go back into "make xconfig" and then reload your stored
configuration ... unless you really want to go back through the entire
xconfig and redo it by hand.
Hope it will solve my problem......

regards
 
Old 08-17-2005, 02:56 AM   #9
masand
Guru
 
Registered: May 2003
Location: INDIA
Distribution: Ubuntu, Solaris,CentOS
Posts: 5,522

Rep: Reputation: 58
Quote:
Originally posted by ruudra
But there is no ".config" file in my sysytem inside the quoted directories

what should i do now...???

regards
that is because ur trying to compile a 2.6 kenel with help from a doc for 2.4 kernel


regards
 
Old 08-17-2005, 03:19 AM   #10
b0nd
Senior Member
 
Registered: Jan 2005
Distribution: Slackware, BackTrack, Windows XP
Posts: 1,020

Original Poster
Rep: Reputation: 45
not at all man !!!
Right from the starting i'm quoting that i'm trying to compile kernel 2.4, and following steps for it only.
I don't know the reason why it wasn't there
But now my problem has been solved.........i found the way of proceeding ahead with keeping the latest compiled files intact for new compilation...........and ya now ".config" file is there.
Any ways thanks to all concerned guys!!!

regards
 
Old 08-17-2005, 12:25 PM   #11
masand
Guru
 
Registered: May 2003
Location: INDIA
Distribution: Ubuntu, Solaris,CentOS
Posts: 5,522

Rep: Reputation: 58
sorry for my mistake!!

just slipped out of my mind while posting that
 
Old 08-17-2005, 01:08 PM   #12
sundialsvcs
Guru
 
Registered: Feb 2004
Location: SE Tennessee, USA
Distribution: Gentoo, LFS
Posts: 5,256

Rep: Reputation: 1076Reputation: 1076Reputation: 1076Reputation: 1076Reputation: 1076Reputation: 1076Reputation: 1076Reputation: 1076
A little potential problem with make oldconfig is that, if you happen to be compiling to remove "everything but the kitchen sink," the old config obviously still has them.

What I like to do is to (after carefully saving the existing .config in a completely different directory, and no longer as a hidden-file) run:
  • make mrproper (to clean the world...)
  • make defconfig (to build a "default" configuration that's actually somewhat smart)
  • make xconfig (to bring up the GUI and let me choose what I want).
  • Safely file a backup copy of the new configuration.
There's a lot of stuff you know you can safely remove, like dozens upon dozens of device drivers for cards that you don't have and never will. But otherwise it's a good idea to move slowly, changing only a few things at a time. Make frequent backup copies of your configurations as you go.
 
  


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
program compiled under kernel <=2.4 don't work under kernel 2.6 mihaimdl Linux - Software 3 11-08-2005 06:09 PM
Kernel compilation problems, distorted video and kernel panic shamrock_uk Linux - Laptop and Netbook 5 08-12-2005 10:53 PM
does kernel-source installs with the compilation cum installtion of a new kernel? luqman Linux - General 18 03-04-2005 07:33 AM
new kernel compiled successfully, but the kernel-source package is the same old? luqman Red Hat 2 03-03-2005 08:41 AM
kernel panic on reboot of newly compiled kernel lyceum Linux - Newbie 4 09-09-2003 09:40 AM


All times are GMT -5. The time now is 04:58 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