Kernel v.2.6.20.4 Released

Man-wai CHANG mwchang
Sat Mar 24 03:38:43 PDT 2007


Man-wai CHANG wrote:
>> Man-wai do you have some sort of process that you use to upgrade? 
>> Everytime a new kernel is announced it seems you are the first on list 
>> to upgrade
> 
> I just repeat the following script:
> 
> 
> 
> ------------------------------------------------------------------------
> 
> #!/bin/bash
> # nm vmlinux | grep -v ... | sort > System.map
> #
> # apply kernel verison upgrade:
> # bzip2 -dc patch-2.6.20.1.bz2 | patch -p1
> #
> # apply any patches if needed
> # cd /usr/src/linux
> # cat /samba/linux/kernel/preempt-kernel-rml-2.4.18-4.patch | patch -Np1
> #
> # the config that made a kernel could always be salvage
> # from /usr/src/linux/arch/i386/defconfig
> # in the rpm linux-source-i386-2.4.2-11D.i386.rpm
> #
> # Suse kernel 2.6.x
> # zcat /proc/config.gz > .config
> # make cloneconfig
> #
> # ubuntu:
> # stock kernel config file in /boot
> # 
> # the current config files is 
> # cp /usr/src/linux/.config
> #
> # make mrproper to clean up (will delete .config)
> #
> # notes: block device LOOP must be compiled into the kernel
> #
> # patch-o-matic: TARPIT, string, owner-socketloopup
> #
> # make menuconfig
> 
> function cpfile()
> {
> 	echo -ne "Installing $1..."
> 	cp -f $1 /boot/$2
> 	echo "done"
> }
> 
> echo 'Remember to patch ip_Conntrack'
> #exit
> 
> ver="2.6.20.4"
> 
> if [ ! -f /usr/src/linux-$ver/.config ] ; then
>   echo '.config not found'
>   exit 1
> fi
> ln -s /usr/src/linux-$ver /usr/src/linux
> cd /usr/src/linux-$ver
> ls
> starttime=`date`
> if make clean &&\
>    make -j2 bzImage &&\
>    make -j2 modules &&\
>    make modules_install
> then
>   cp -f /usr/src/linux-$ver/arch/i386/boot/bzImage /boot/vmlinuz-$ver
>   cp -f /usr/src/linux-$ver/System.map /boot/System.map-$ver
>   cp -f /usr/src/linux-$ver/.config /boot/config-$ver
>   cp -f /usr/src/linux-$ver/.config /home/toylet/public_html/scripts/config-$ver.txt
>   cp -f /usr/src/linux-$ver/compile.kernel.txt /home/toylet/public_html/scripts
>   cd /lib/modules/$ver
>   depmod -a $ver -F /boot/System.map-$ver
>   mkinitrd -o /boot/initrd.img-$ver $ver
>   echo $starttime
>   date
>   exit 0
> fi
> exit 2
> #
> # adjust /boot/grub/menu.lst, or /etc/lilo.conf
> # to update grub : grep -v ^# /etc/grub.conf | grub --batch
> #
> # remove the initrd line
> # video=1024x768-32 at 85
> #
> # under Ubuntu:
> # update-grub
> #
> # fedora core
> # grub-install /dev/hda
> #
> 
> 
> ------------------------------------------------------------------------
> 
> _______________________________________________
> Linux-users mailing list ( Linux-users at linux-sxs.org )
> Unsub/Password/Etc: http://mail.linux-sxs.org/cgi-bin/mailman/listinfo/linux-users
> 
> ***  OFF TOPIC conversations should get sent to general at linux-sxs.org.  This rule will be strictly enforced.  ***
> 
> Need to chat further on this subject? Check out #linux-users on irc.linux-sxs.org !

a few steps not listed.

cd /usr/src
bunzip2 -dck /path/to/linux-2.6.20.4.tar.bz2 | tar xv
cd linux-2.6.20.4
cp /path/to/config-2.6.20.3 .config
make oldconfig
make menuconfig
./compile.kernel.txt
update-grub



-- 
  .~.    http://changmw.homeip.net
 / v \   May the Force and Farce be with you! Linux 2.6.20.4
/( _ )\  (Ubuntu 6.10)  18:36:01 up 5:48 0 users
  ^ ^    load average: 1.02 1.01 1.00
news://news.3home.net news://news.hkpcug.org news://news.newsgroup.com.hk



More information about the Linux-users mailing list