LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   Update Linux Kernel (https://www.linuxquestions.org/questions/linux-newbie-8/update-linux-kernel-4175458186/)

ankit_singh 04-15-2013 07:20 AM

Update Linux Kernel
 
Hello,

Currently am having Ubuntu 2.6.32 on my machine and want to update it with kernel 3.8.7.
I have followed below steps:-
1.) Downloaded Kernel 3.8.7 from kernel.org
2.) Compiled it with below steps
a.) make
b.) make modules
c.) make modules_install (after have root access "su")
d.) make install

After above steps i could see initramfs-3.8.7.img, System.map-3.8.7 and vmlinux-3.8.7 files in/boot but still on rebooting am not seeing any option for 3.8.7 boot and its booting still the old kernel (2.6.32)

Please let me know if am missing any thing??
I also noticed that congfig-3.8.7 file is missing (could see config-2.6.32-131.0.15.e16.x86_64, so thought same should be there for 3.8.7 also), is this the reason? If so then how to generate this file.

Regards,
Ankit Singh

Soadyheid 04-15-2013 08:19 AM

If you've got all the relevant files in /boot you'll need to run
Code:

update-grub
to let the grub boot loader update itself and include the new kernel in it's boot list.

I'm running Ubuntu 10.4 LTS which is still using the 2.6.32-46 kernel which I keep up to date with the Software Update Manager. It keeps offering me an upgrade to Ubuntu 12.something (The one with Unity desktop which I don't really want yet.), it's running the 3.n kernel.
I'm not sure if there are likely to be any problems jumping from 2.6.32 up to 3.8.7.

Play Bonny!
:hattip:

ankit_singh 04-15-2013 08:30 AM

I checked with /boot/grub/menu.lst and it has entry for both the version (2.6.32 and 3.8.7)

273 04-15-2013 08:53 AM

I don't know how good it is but this shows you how to build .deb kernel packages so you can manage them with dpkg and apt-get. I've used it and it seems do do OK.
http://mapopa.blogspot.co.uk/2009/01/compiling-2.html

colorpurple21859 04-15-2013 09:54 AM

Quote:

I checked with /boot/grub/menu.lst and it has entry for both the version (2.6.32 and 3.8.7)
Did you run update-grub? What version of Ubuntu or you using, most current versions of Ubuntu uses grub2 which uses the /boot/grub/grub.cfg verses legacy grub which uses /boot/grub/menu.lst.

goumba 04-15-2013 09:59 AM

Follow the instructions on the page 273 linked, but I think you get everything you need if instead of:

Code:

make-kpkg clean
fakeroot make-kpkg --initrd --append-to-version=-vanillaice kernel_image kernel_headers
cd ..
dpkg -i linux-image-3.8.*

this should be sufficient:

Code:

make-kpkg clean
fakeroot make-kpkg --initrd --append-to-version=-vanillaice binary
cd ..
dpkg -i linux-image-3.8.*

the latter will produce all packages you may need.

273 04-15-2013 10:15 AM

Of course you can change vanillaice to something less cheezy if you want also. I tried using localmodconfig rather than menuconfig too but I'm new to this so I'm still finding out the differences.

goumba 04-15-2013 10:26 AM

One more suggestion for the original poster. Before compiling for yourself, if a stock kernel works for you, add

Code:

http://cdn.debian.net/ experimental main
to /etc/apt/sources.list and pull the kernel from there. If it doesn't require too many packages to be removed, it may be safer. However, if it will remove packages you know you need or are unsure of, compile yourself.

This is how I get my newer kernels on a Wheezy system, but that's likely newer than yours and the rest of the packages are already up to date.

Soadyheid 04-15-2013 10:45 AM

Quote:

but still on rebooting am not seeing any option for 3.8.7
So you haven't run
Code:

update-grub
yet? See colourpurple21859's post above. Ubuntu now uses grub2, you should get the new kernel as an option to boot from.

You could upgrade to Ubuntu 12.4 which I believe has the 3.x kernel then accept any further updates offered rather than installing by hand.

Play Bonny!
:hattip:

ankit_singh 04-16-2013 02:33 AM

Thanks to all from the help, actually issue was in menu.lst file as it was having 3.8.7 as hidden....!!!


All times are GMT -5. The time now is 10:34 AM.