Help - Search - Members - Calendar
Full Version: how do you rebuild the kernel ? ( for dummies )
The Planet Forums > Operating Systems > Red Hat Linux
patrix
I have this message in my whm:

You are running an insecure kernel (2.4.20-20.9). You should upgrade to a newer version as soon as possible to avoid your system being compromised.

It's nice to have these messages, but would be nicer to also have the solution icon_redface.gif

How do you upgrade !?
pat.
clearsignal
Pat, here's what I did - following some of the instructions in the forum (darned if I can find them right now)

Note: If you are on a Silver Mgmt plan, submit a ticket and they will do this for you.

SSH into your box as root

CODE
up2date --configure

Select item #8 (and remove kernel* from the skip list)
Follow the instructions to save...now I am a paranoid type so I ran the program again to make sure my save took properly wink.gif

Then...
CODE
up2date kernel

You should see the system downloading and installing the kernel.



Now the part that got me was that it just kind of downloaded the kernel to the right spots. But in order to call it when it boots, you will have to edit your grub.conf file.(assuming your system is using grub, my rehat was by default)

CODE
pico -w /boot/grub/grub.conf

You will see something similar to this:
# grub.conf generated by anaconda
#
# Note that you do not have to rerun grub after making changes to this file
# NOTICE: You have a /boot partition. This means that
# all kernel and initrd paths are relative to /boot/, eg.
# root (hd0,0)
# kernel /vmlinuz-version ro root=/dev/sda2
# initrd /initrd-version.img
#boot=/dev/sda
default=0
timeout=3
splashimage=(hd0,0)/grub/splash.xpm.gz
title Red Hat Linux (2.4.20-24.9)
root (hd0,0)
kernel (hd0,0)/vmlinuz-2.4.20-24.9 ro root=LABEL=/
initrd (hd0,0)/initrd-2.4.20-24.9.img

title Red Hat Linux (2.4.20-20.9)
root (hd0,0)
kernel (hd0,0)/vmlinuz-2.4.20-20.9 ro root=LABEL=/
initrd (hd0,0)/initrd-2.4.20-20.9.img
title Red Hat Linux (2.4.20-18.9)
root (hd0,0)
kernel (hd0,0)/vmlinuz-2.4.20-18.9 ro root=LABEL=/
initrd (hd0,0)/initrd-2.4.20-18.9.img
title Red Hat Linux (2.4.20-icon_cool.gif
root (hd0,0)
kernel (hd0,0)/vmlinuz-2.4.20-8 ro root=LABEL=/
initrd (hd0,0)/initrd-2.4.20-8.img

You can see a pattern here, the top file is the one that's called first I believe. The section above that is BOLDED was what I added. Also, you might want to make sure that those files acutally exist in your /boot/ directory. (make sure the numbers exist, I believe there is a new kernel out today, so adjust the file names accordingly.

FYI If you want to see your installed kernels:
CODE
rpm -q kernel


EDIT: also, go back into up2date --configure and add kernel* back to the skip list if you don't want it to constantly be updated.

Good luck with it, this was my first attempt updating the kernel and it went fine for me...however if this is a production server for you and you don't want to risk the downtime, contact SM for assistance. Don't forget to reboot for the kernel to take.

Seasons Greetings,
Russ
allanh
does servermatrix update Kernel for you automatically?
clearsignal
From what I've heard...no.

You have to specifically ask for it I believe!
That's assuming you are on the Silver Mgmt Plan.
Ferret_dude
I got a server wich uses lilo as bootloader what are the steps for uing lilio instead of grub ??
Ferret_dude
QUOTE (allanh)
does servermatrix update Kernel for you automatically?
you have to open a ticket to get it updated .. you can also specify a time of day wich suite you the best ( best time is when you server has minimal traffic )
This is a "lo-fi" version of our main content. To view the full version with more information, formatting and images, please click here.
Invision Power Board © 2001-2010 Invision Power Services, Inc.