LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
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 06-28-2006, 05:33 PM   #1
saf
LQ Newbie
 
Registered: Mar 2004
Location: Bucharest
Distribution: Slackware 10.2
Posts: 26

Rep: Reputation: 15
Question Creating a custom kernel .tgz


Hello

I have two questions for you:
1. is there a small how-to for creating a packages with a custom compiled kernel? I have the sources from current/testing/source/linux-2.6.16.22, but I would like to make a package with 2.6.17.1 and I don't know exactl the what-and how. Is it enought if I copy the tar.bz2 of the original kernel sources, create the kernel config and modify the versions in the .SlackBuild files? (also the "stock" kernel options are not enough)
2. are there any pro/con opinios for "big" kernels? Let me explain: I have several servers and I want to make a kernel package to install on these. The only difference will be in drivers/raid. Since I don't quite like initrd, I would like to statically build the essential drivers into the kernel (filesystem, raid, lvm, chipseturi), so theat any machine will be able to get to the module loading section in the boot sequence. The rest will be modules. This will increase the size of the bzImage. Did anoyone notice any performance hit in these situations?

Thanks in advance.
 
Old 06-28-2006, 06:20 PM   #2
PsychoticDude85
Member
 
Registered: Dec 2005
Distribution: Slackware -current - KDE 3.5.10
Posts: 62

Rep: Reputation: 15
If you are using a server wouldn't you want to stick to the 2.6.16.x branch? That's now the stablising branch with most new features only going into the 2.6.17.x kernel tree. If you want a server then I would have thought the stable branch would have been more fitting as servers have to remain up and running for a long time and having a stable base would be a better way to achieve this.
 
Old 06-28-2006, 11:17 PM   #3
MS3FGX
LQ Guru
 
Registered: Jan 2004
Location: NJ, USA
Distribution: Slackware, Debian
Posts: 5,852

Rep: Reputation: 361Reputation: 361Reputation: 361Reputation: 361
I build 98% of my drivers into the kernel, and generally only have 1 or 2 modules. There is nothing wrong with that, and to be honest, that has always made a lot more sense to me. If it is hardware I never plan on removing, why make the driver for it modular?

As for making the package, that is not too hard. Basically build the kernel and modules as you normally would, and install everything on the one machine. Do some testing, make sure it all works. Then remove all of the Slackware default kernel packages from the system, and have only your new kernel on it.

Then do something like

mkdir /tmp/kernel_pkg
mkdir /tmp/kernel_pkg/lib
mkdir /tmp/kernel_pkg/etc
cd /tmp/kernel_pkg
cp -a /boot ./
cp -a /lib/modules/ ./lib/
cp /etc/lilo.conf ./etc/
makepkg kernel-2.6.17.1-i386-1.tgz

That will make a Slackware package that contains the current kernel, modules, and lilo configuration file. To install that on another machine, just install it as normal, and make sure to run "lilo" after it is done, to update your boot loader.

Do note that it is fairly dangerous to do it this way, and you should fully expect for something to go wrong the first few times until you tweak it properly.
 
Old 06-29-2006, 02:07 PM   #4
saf
LQ Newbie
 
Registered: Mar 2004
Location: Bucharest
Distribution: Slackware 10.2
Posts: 26

Original Poster
Rep: Reputation: 15
Quote:
Originally Posted by PsychoticDude85
If you are using a server wouldn't you want to stick to the 2.6.16.x branch? That's now the stablising branch with most new features only going into the 2.6.17.x kernel tree. If you want a server then I would have thought the stable branch would have been more fitting as servers have to remain up and running for a long time and having a stable base would be a better way to achieve this.
As far as I know, the "numbering plan" for the kernel releases has changed, so the odd numbered versions are no longer in the testing stage.
 
  


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
Creating a custom process id cbutcher Linux - General 2 04-29-2005 07:59 AM
Creating RPM's from .tgz files kaplan71 Linux - General 1 03-24-2005 09:23 PM
checkinstall creating i386 tgz xushi Slackware 12 10-01-2004 04:38 AM
Creating custom RPM kernel... Enlightened Linux - Software 1 07-02-2004 04:35 PM
creating custom locale jinujose Linux - General 1 10-21-2003 01:50 AM

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

All times are GMT -5. The time now is 08:11 PM.

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