[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: How to get the right source

On Thursday 27 July 2006 14:43, Bill Ranck wrote:
> Hello folks,
>    I am new to the 64 bit stuff and I need to rebuild my kernel for
> multiple processors.  I know I should apt-get the source packages, but
> which packages and from where?  My /etc/apt/sources.list has the
> following:
> deb http://debian.csail.mit.edu/debian-amd64/debian sarge main contrib
> deb http://security.debian.org/ stable/updates main
>    I have installed am running this on a Dell 2650 with Intel
> processors.  Here is the uname -a line:
> Linux ripberger 2.6.12-1-amd64-generic #1 Fri Jul 22 18:12:08 CEST 2005
> x86_64 GNU/Linux
>    I assume that I just need to download the kernel sources, do the
> "make menuconfig" thing and make the new kernel from there.  Any other
> cautions or suggestions?

Your best bet is to install "kernel-package".  This automates the Slackware / 
Gentoo way of compiling a kernel, allowing you to make .deb files with a 
kernel image, modules &c. which can jsut be installed using dpkg.  As for the 
kernel source .tar.bz2 file, get this from kernel.org.  There should already 
be a config file in /boot with the options of the installed kernel:  copy 
this to your kernel source directory and
# make oldconfig
This will make a new config file. You will be prompted  (y/n/m)  about any new 
features added in the meantime; anything that has not changed since the 
existing kernel will be passed through unchanged.  Then
# make menuconfig
and change what needs changing.  (You'll need libncurses5-dev for menuconfig 
to work, IIRC.)
Then use make-kpkg to create your own kernel package.

NB, if this is your first kernel compile, carefully read as much documentation 
as you can find, and absolutely don't take any notice of anything that isn't 
specific to Debian/Ubuntu.  Also, don't compile a new kernel with the same 
minor version number as the one you're running  (keep an older kernel handy 
in case you ever have to do that);  and have a bootable CD nearby so you can 
sort out any bootloader configuration errors.  (Boot from CD, make a 
directory, mount HDD partitions there, enable swap and chroot into the HDD.  
Make any necessary changes.  EXIT THE CHROOT BEFORE SHUTTING DOWN or you may 
lose some or all of the changes you made.)

delta echo bravo six four at earthshod dot co dot uk

Reply to: