Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
Grabbing the current kernel config
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Installing Gentoo
View previous topic :: View next topic  
Author Message
telex4
l33t
l33t


Joined: 21 Sep 2002
Posts: 704
Location: Reading, UK

PostPosted: Fri Apr 11, 2003 5:49 pm    Post subject: Grabbing the current kernel config Reply with quote

Hey, I don't need to do this but I'm asking because I'm sure someone will know, and I was trying to remember it this afternoon. When you're configuring your kernel, is there a command you can use that grabs the configuration of the kernel that's currently residing in your memory (i.e. is "running") and dump it to a config file, so you can configure a new set of sources more easily? I swear I read about it somewhere, but now I can't find anything about it!
Back to top
View user's profile Send private message
Jimbow
Guru
Guru


Joined: 18 Feb 2003
Posts: 597
Location: Silver City, NM

PostPosted: Fri Apr 11, 2003 6:09 pm    Post subject: Reply with quote

If you are running a recent kernel (might need a kernel option set too) then "cat /proc/config" does what you want.
_________________
After Perl everything else is just assembly language.
Back to top
View user's profile Send private message
telex4
l33t
l33t


Joined: 21 Sep 2002
Posts: 704
Location: Reading, UK

PostPosted: Fri Apr 11, 2003 11:11 pm    Post subject: Reply with quote

Hmm, I don't think that was it, but thanks anyway
Back to top
View user's profile Send private message
telex4
l33t
l33t


Joined: 21 Sep 2002
Posts: 704
Location: Reading, UK

PostPosted: Sat Apr 26, 2003 10:09 pm    Post subject: Reply with quote

Whilst looking through kernel stuff before trying the 2.5 series, I came across:

make oldconfig

which appears to make a .config based on the kernel that is currently running. I'm going to try it out - can anyone else shed any more light on this command?

EDIT: just tried it, and it seems to do what I said, prompting you with the "make config" style configuration choices for new/changed options in the new sources. A little hairy given that I usually use menuonfig, but I'll see if I get a good result from it :)
Back to top
View user's profile Send private message
Jimbow
Guru
Guru


Joined: 18 Feb 2003
Posts: 597
Location: Silver City, NM

PostPosted: Sat Apr 26, 2003 11:15 pm    Post subject: Reply with quote

I don't think "make oldconfig" does what you think. It is used for when you upgrade to a different kernel. You can't just copy .config over to the new src directory and expect it to work because kernel options change with different source releases.

To use "make oldconfig" you first copy your current .config to the new /usr/src/linux directory and then run "make oldconfig". As you say it will then prompt you with questions (usually about new kernel options that do not exist in your old .config.

If "make oldconfig" did what you think it does then there would have been no reason for them to add the option to have /proc/config in the newer kernels.
_________________
After Perl everything else is just assembly language.
Back to top
View user's profile Send private message
Cossins
Veteran
Veteran


Joined: 21 Mar 2003
Posts: 1136
Location: Copenhagen, Denmark

PostPosted: Sat Apr 26, 2003 11:37 pm    Post subject: Reply with quote

Just a thought:
make oldconfig could be reading the old configuration from /proc/config...
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Installing Gentoo All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum