[techtalk] Kernel upgrade for Red Hat 6.0

Shannon Wells shannonw at cygnus.com
Thu Sep 30 11:28:26 EST 1999


I'd like to add, and hopefully this doesn't need to be said, that with lilo
it's easy to be able to pick more than one kernel boot image to boot from,
in case your newly compiled kernel is hosed.

Just copy the lines in /etc/lilo.conf (I think, I'm doing all this from
memory right now) below the ones for the original kernel, and modify the new 
copy to point to the new boot image file, then run 'lilo' so lilo knows about 
the new boot image.

I believe the Kernel-HOWTO will say all this, but I think maybe it can't be
said too often to always have a backup kernel.

I too always use symlinks to point to the currently used version of source 
code.  I always keep a copy of the old source code (for any package), and the 
new /usr/src/[blah]  link points to /usr/src/[blah].[version] directory.

ObNewbieAnecdote:  Last year I was very new to Linux and having never configured
a kernel before I did not know that x86 architecture was ELF format.  So I
did not compile it into the kernel, as I had a small, slow machine and wanted
a small kernel!  Of course the kernel did not work!  So I asked one of my 
coworkers about it, who is The Alpha Linux Kernel Hacker, and he pointed out
that my kernel was not going to run if it didn't understand its own format.
Duh.  *shame*. 

So that's a lesson for you, if you're a beginner don't try to be smarter than
the defaults.  :)

Shannon

On Wed, 29 Sep 1999, Beverly Guillermo wrote:

> I recommend backing up everything in the source file, just in case
> something goes wrong.
> 
> tar zcvf old-kernel.tar.gz /usr/src/linux/*
> 
> > - i moved the tarball to /usr/src/ , and untarred it, and then realized
> > that it was expanding into the directory "linux", and since there was
> > already a symlink called "linux" which pointed into a dir for the older
> > version, i wound up with a mixture of stuff from the old and new versions.
> > oops.  so the safest thing to do is probably to create a new
> > empty dir, put
> > the tarball in there, and untar it there, and then move it to where you
> > want it.  (this is probably a good idea in general when untarring any
> > tarball...)
> 
> here's my naming convention: =)
> [root at stalefish]
> (/usr/src/)$ mv /usr/src/linux-2.2.11 /usr/src/linux-2.2.12
> [root at stalefish]
> (/usr/src/)$ mkdir linux-2.2.12
> [root at stalefish]
> (/usr/src/)$ tar xzvf linux-2.2.12.tar.gz linux2.2.12
> [root at stalefish]
> (/usr/src/)$ rm linux
> [root at stalefish]
> (/usr/src/)$ ln -s linux-2.2.12 linux
> 
> 
> > - when going through the possible modules to include, unless you're short
> > on disk space, it's probably a good idea to just include everything you
> > think there's a chance you might conceivably someday want.  if
> > something is
> > compiled as a module, it won't slow down your kernel when it's not in use.
> > i didn't think i'd need IP aliasing, which allows a machine to have more
> > than one IP address, so i didn't compile that in, but then i realized that
> > to do IP masquerading, i needed to give my linux box a "real" IP address
> > *and* an address on the private network.  so i did need IP aliasing after
> > all.  so i had to go back and recompile the kernel...
> 
> It's a good practice for anybody to put all the modules in... however, if
> you DO know all about your system, I recommend really configuring it.  One
> of
> my kernels is only 394Kb and it loads up without a lot of delay because I
> took
> stuff out that I didn't need. ;)
> 
> Beverly
> 
> 
> ************
> techtalk at linuxchix.org   http://www.linuxchix.org
> 
> 

Shannon E. Wells		Web:  		http://www.cygnus.com
Quality Engineer		Support line:	408-542-9601
Cygnus Solutions		Email:		shannonw at cygnus dot com


************
techtalk at linuxchix.org   http://www.linuxchix.org




More information about the Techtalk mailing list