LinuxQuestions.org
Visit Jeremy's Blog.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware
User Name
Password
Slackware This Forum is for the discussion of Slackware Linux.

Notices


Reply
  Search this Thread
Old 03-06-2008, 02:12 AM   #1
john99
Member
 
Registered: Mar 2007
Posts: 46

Rep: Reputation: 15
list all custom kernel konfigurations possible?


Hello,

I checked the actual kernel-konfiguration with `make menuconfig`.

Question:
Is there a way to list or printout ALL custom kernel konfigurations? How?



Thank's a lot in advance for every feedback!

John
 
Old 03-06-2008, 10:17 AM   #2
TSquaredF
Member
 
Registered: Dec 2005
Location: "The South Coast of Texas"
Distribution: Slackware64-current
Posts: 564

Rep: Reputation: Disabled
I guess I don't understand your question, John. Trying to list ALL custom kernel configs to me sounds like trying to list all prime numbers, a tough job. In my case, I want to use the same kernel on several different computers around here, so I start with the config from the kernel-generic-smp package, then change what I want, normally just "CONFIG_HZ_1000=y" & "CONFIG_APM=n". Then I go down to the filesystem section & build ext2 & ext3 into the kernel, instead of as modules, so that I won't have to use an initrd. I started with the config file from Slackware 12 & have used it in a number of kernels since; it works quite well in several different machines.
Regards,
Bill
 
Old 03-06-2008, 05:20 PM   #3
T3slider
Senior Member
 
Registered: Jul 2007
Distribution: Slackware64-14.1
Posts: 2,367

Rep: Reputation: 843Reputation: 843Reputation: 843Reputation: 843Reputation: 843Reputation: 843Reputation: 843
If you're trying to show everything you've changed, you could do a `diff` on your new .config and the original .config included with Slackware (or whatever .config you started with). This would show all of the differences. For example:
Code:
$ diff .config.old .config > CustomKernel.txt
Admittedly this will be VERY messy, especially if you are using .config files from two different kernel versions (where the names of some options may be changed, some options may have been removed, and some added).
 
Old 03-17-2008, 05:21 AM   #4
john99
Member
 
Registered: Mar 2007
Posts: 46

Original Poster
Rep: Reputation: 15
Thank's a lot for te helpful feedback! At the moment I would be happy to be able to compare the the .config of the same kernel-versions.

Question:
Were do I find/download the "original" .config in order to be able to compare it with the .config of a "Slackwaree remaster"?


Thank's a lot in advance for your help!

John
 
Old 03-17-2008, 08:08 AM   #5
mcnalu
Member
 
Registered: Dec 2006
Location: Glasgow, UK
Distribution: Slackware current
Posts: 423

Rep: Reputation: 73
The config files for the kernels shipped with slackware can be found under the kernels dir on the CD, or
in the same dir on a mirror site, e.g.:

ftp://ftp.slackware.com/pub/slackwar...e-12.0/kernels
 
Old 03-17-2008, 08:31 AM   #6
TSquaredF
Member
 
Registered: Dec 2005
Location: "The South Coast of Texas"
Distribution: Slackware64-current
Posts: 564

Rep: Reputation: Disabled
And if you have customized a kernel, your config is "/usr/src/linux-2.6.XX.YY/.config".
Regards,
Bill
 
Old 03-17-2008, 08:53 AM   #7
duryodhan
Senior Member
 
Registered: Oct 2006
Distribution: Slackware 12 Kernel 2.6.24 - probably upgraded by now
Posts: 1,054

Rep: Reputation: 46
rather it is in /lib/modules/$(uname -r)/source
 
Old 03-17-2008, 06:06 PM   #8
TSquaredF
Member
 
Registered: Dec 2005
Location: "The South Coast of Texas"
Distribution: Slackware64-current
Posts: 564

Rep: Reputation: Disabled
Quote:
Originally Posted by duryodhan View Post
rather it is in /lib/modules/$(uname -r)/source
Code:
$ ls -l /lib/modules/$(uname -r)/source
lrwxrwxrwx 1 root root 23 2008-03-10 10:55 /lib/modules/2.6.24.3-t2f/source -> /usr/src/linux-2.6.24.3
Six of one, half a dozen of another.
Regards,
Bill
 
Old 03-17-2008, 10:34 PM   #9
T3slider
Senior Member
 
Registered: Jul 2007
Distribution: Slackware64-14.1
Posts: 2,367

Rep: Reputation: 843Reputation: 843Reputation: 843Reputation: 843Reputation: 843Reputation: 843Reputation: 843
Actually TSquaredF, if you don't build kernels in /usr/src, your method doesn't work. duryodhan's method is more foolproof. I'm just saying this as an idiot that builds his kernels as an unprivileged user in a special folder in my home directory to avoid screwing anything up and remaining logged in as root for too long. But if you're 'normal', /usr/src/linux-2.6.XX.YY/.config will work.
 
Old 03-18-2008, 04:28 PM   #10
TSquaredF
Member
 
Registered: Dec 2005
Location: "The South Coast of Texas"
Distribution: Slackware64-current
Posts: 564

Rep: Reputation: Disabled
Quote:
Originally Posted by T3slider View Post
Actually TSquaredF, if you don't build kernels in /usr/src, your method doesn't work. duryodhan's method is more foolproof. I'm just saying this as an idiot that builds his kernels as an unprivileged user in a special folder in my home directory to avoid screwing anything up and remaining logged in as root for too long. But if you're 'normal', /usr/src/linux-2.6.XX.YY/.config will work.
Yes, you are right. I need to change the way I compile kernels.
Regards,
Bill
 
Old 05-16-2008, 02:13 AM   #11
john99
Member
 
Registered: Mar 2007
Posts: 46

Original Poster
Rep: Reputation: 15
Quote:
Originally Posted by T3slider View Post
If you're trying to show everything you've changed, you could do a `diff` on your new .config and the original .config included with Slackware (or whatever .config you started with). This would show all of the differences. For example:
Code:
$ diff .config.old .config > CustomKernel.txt
Admittedly this will be VERY messy, especially if you are using .config files from two different kernel versions (where the names of some options may be changed, some options may have been removed, and some added).

Im trying unsuccessfully (e.g. with 'locate .config') to find the .config on a system booted with a Slackware/Slax LiveCD. (I do know that normally the .config can be found in e.g. # cd /usr/src/linux-2.6.19.5)


Questions:
1.
Where(path) is the .config normally stored on a Slackware based LiceCD?

2.
And what's the best approach to find the kernel config file(.config) ?




Thank's a lot in advance for your help!

John
 
Old 05-16-2008, 04:33 AM   #12
gnashley
Amigo developer
 
Registered: Dec 2003
Location: Germany
Distribution: Slackware
Posts: 4,928

Rep: Reputation: 612Reputation: 612Reputation: 612Reputation: 612Reputation: 612Reputation: 612
I would guess that the live cd doesn't contain the sources at all. You should be able to get the configuration of the running kernel, though, by looking at
the entry in /proc/config.gz(if the kernel was compiled with proc-config support) with this command:
'zcat /proc/config.gz'
 
Old 05-23-2008, 04:12 AM   #13
john99
Member
 
Registered: Mar 2007
Posts: 46

Original Poster
Rep: Reputation: 15
Quote:
Originally Posted by gnashley View Post
I would guess that the live cd doesn't contain the sources at all. You should be able to get the configuration of the running kernel, though, by looking at
the entry in /proc/config.gz(if the kernel was compiled with proc-config support) with this command:
'zcat /proc/config.gz'

Thank you very much for your help, 'zcat /proc/config.gz' does work with that LiveCD :-)

But the size of the LiveCD config ('zcat /proc/config.gz') is only about 20k and the original .config (downloaded from ftp://ftp.slackware.com/pub/slackwar.../kernels)found in the folder huge.s is about 70kb.


Therefore the output of the command

$ diff .config.old .config > CustomKernel.txt

is very confusing for me..

Questions:
Is it required to delete all non existent lines in the .config (downloaded from ftp://ftp.slackware.com/pub/slackwar...e-12.0/kernels) in oder to be able to compare it with the .config gfrom the LiveCD ('zcat /proc/config.gz')? Am I doing something wrong?

Or should such a compare task be done with an other tool?



Thank you very much for any help!

John
 
Old 05-23-2008, 05:02 AM   #14
gnashley
Amigo developer
 
Registered: Dec 2003
Location: Germany
Distribution: Slackware
Posts: 4,928

Rep: Reputation: 612Reputation: 612Reputation: 612Reputation: 612Reputation: 612Reputation: 612
The info in /proc/config only contains the lines which are marked with 'y' or 'm', that is, only the options which were chosen to be hard-linked or compiled as modules. The full .config file contains other lines like comments, which begin with '#' and also the options which are not selected, which have this syntax:
# CONFIG_M386 is not set.

If you use the command 'cat .config |grep -v '^#^' it should give an output very similar to what's in /proc/config. Or, you could do this:
zcat /proc/config.gz > .config
then run:
make oldconfig
The .config should then have a more normal look (it gets re-written by the oldconfig rule).
 
  


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
Creating custom headers to match a custom kernel utanja Debian 2 06-08-2007 03:15 PM
Custom kernel image on custom slack build using CUSS nykey Slackware 2 07-15-2006 03:05 AM
Kernel-Patch Debian Logo 2.6.2 not correctly working for custom kernel 2.6.11 smp deepclutch Debian 3 06-27-2005 03:59 AM
C++, using custom function to sort an std::list R00ts Programming 3 01-03-2005 09:41 AM
New FAQ topic: Should I edit my kernel configuration?/Should I build a custom kernel? chort *BSD 10 09-10-2004 11:15 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware

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