Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
[Solved] Accessing .config from /proc/config.gz
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Kernel & Hardware
View previous topic :: View next topic  
Author Message
Thomas2010
n00b
n00b


Joined: 27 May 2010
Posts: 40
Location: Waynesboro, PA, USA

PostPosted: Wed Oct 05, 2011 4:57 pm    Post subject: [Solved] Accessing .config from /proc/config.gz Reply with quote

I renamed my .config file to .config.old so I could run
Code:
make mrproper
giving me a "clean slate" to build an updated kernel, but it got deleted. I should have used a different suffix. Anyways, I am sure I included the kernel options to save the .config file in the kernel but I do not know how to extract it. I tried
Code:
/proc/config.gz /boot/kernel-2.6.39-r3
and I got the message
Code:
-bash: /proc/config.gz :No such file or directory


Does the error I got mean I did not include the option in my kernel? Is there a way for me to find out if I did include the options? What is the actual syntax and where would my .config file get extracted to if I can get it?


Last edited by Thomas2010 on Wed Oct 05, 2011 5:57 pm; edited 1 time in total
Back to top
View user's profile Send private message
DirtyHairy
l33t
l33t


Joined: 03 Jul 2006
Posts: 608
Location: Würzburg, Deutschland

PostPosted: Wed Oct 05, 2011 5:02 pm    Post subject: Reply with quote

If you included the configuration into the running kernel, /proc/config.gz exists, if you didn't, it doesn't. If the pseudofile exists, it just looks like a regular, gzipped file, so "gunzip /proc/config.gz" will create a "config" file in your current working directory.
Back to top
View user's profile Send private message
Thomas2010
n00b
n00b


Joined: 27 May 2010
Posts: 40
Location: Waynesboro, PA, USA

PostPosted: Wed Oct 05, 2011 5:57 pm    Post subject: Reply with quote

Thank you for your help. /proc/config.gz does not exist so it is back to the drawing board for me.
Back to top
View user's profile Send private message
Jaglover
Watchman
Watchman


Joined: 29 May 2005
Posts: 8291
Location: Saint Amant, Acadiana

PostPosted: Wed Oct 05, 2011 6:06 pm    Post subject: Reply with quote

Next time try make clean or back up the .config first (good idea), make mrproper will return sources into pristine condition, everything gets removed.
_________________
My Gentoo installation notes.
Please learn how to denote units correctly!
Back to top
View user's profile Send private message
javeree
Guru
Guru


Joined: 29 Jan 2006
Posts: 458

PostPosted: Thu Oct 06, 2011 8:19 am    Post subject: Reply with quote

Possiby you configured the config settings as a module. Then you don't see it until you load the module.

try

modprobe configs
[ -f /proc/config.gz ] && zcat /proc/config.gz > /usr/src/linux/.config
Back to top
View user's profile Send private message
Thomas2010
n00b
n00b


Joined: 27 May 2010
Posts: 40
Location: Waynesboro, PA, USA

PostPosted: Thu Oct 06, 2011 3:49 pm    Post subject: Reply with quote

Since I lost everything I just started over and made sure I selected the options to create the config.gz file. My mistake was renaming the file .config.old instead of something else. I have had other copies of the .config file with names starting with .config and they were not deleted when I ran make mrproper.
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Kernel & Hardware 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