[Techtalk] kernel upgrades

Mary Gardiner linuxchix at puzzling.org
Thu Oct 11 18:59:38 EST 2001


On Thu, Oct 11, 2001 at 08:52:42AM +0100, Lee Blackwell wrote:
> [root at bella /usr/src]# tar zxvf /home/lee/linux-2.4.10.tar.gz .
> 
> By default, kernel tarballs are stored in the 'linux' directory.  *This*
> is why you unlink /usr/src/linux, because otherwise you'd overwrite your
> original source tree (bad idea!)

I find it is perfectly adequate to compile kernels in my home directory,
but other people may have different systems for keeping their kernels in
order.

If you're compiling the kernel in a place your user has write access to,
you don't need to be root. Only 'make modules_install', if you need that
step, and copying the bzImage to the right place need to be done as
root. As the README says, "do not take the name of root in vain".

On that note, there are three things I would like to recommend to novice
kernel builders:

* In the source you untar, there will be a README file. Read it. Oh yes.
* Be sure to rerun lilo.
* As others have said, be sure to have a backup kernel.

I compiled a new kernel the other day, and realised I hadn't built the
DOS VFAT file system module, so I rebuilt the kernel and every time I
booted it told me I had an invalid bzImage file. So I booted into an old
kernel, recompiled, same thing. Third compile. Foruth compile. Realised I
hadn't rerun lilo after the second build. Hence the error message. Reran
lilo and all was fine.

If I hadn't had an old kernel around to boot into that story would be
more than "I stupidly wasted my time for an hour", it would be "I had to
find a boot disk and ..."

-Mary.

-- 
Mary Gardiner
<mary at puzzling.org>




More information about the Techtalk mailing list