Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
Howto: update the kernel? [solved?]
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Kernel & Hardware
View previous topic :: View next topic  
Author Message
mno
Guru
Guru


Joined: 29 Dec 2003
Posts: 454
Location: Toronto, Canada

PostPosted: Fri Mar 11, 2005 5:12 am    Post subject: Howto: update the kernel? [solved?] Reply with quote

Hi,

What is the proper procedure to update the Gentoo kernel (using portage if possible)? I've done a search on the boards, but didn't get anything helpful. Sorry if this was answered before.

Also, what files would you recommend that I backup before going on and doing this?

Thanks,
Max
_________________
"Hello and goodbye. As always." | You can't use   here?? | Unanswered


Last edited by mno on Thu Mar 17, 2005 7:42 am; edited 1 time in total
Back to top
View user's profile Send private message
c0rax
n00b
n00b


Joined: 22 Nov 2004
Posts: 13

PostPosted: Fri Mar 11, 2005 5:29 am    Post subject: Reply with quote

Hey bro, don't appologize thats a good question. And for a long time i was scared to do it without help. First of all you dont ned to really back anything up casue you can have several kernels sitting on your /boot partition all at once and boot from them all if you want to by adding an entry into you grub conf. ok so here goes a step by step to the best of my ability.

1. emerge the latest kernel sources. do this by doing an emerge gentoo-dev-sources after a fresh sync.

2. configure your new kernel. this is exaclty the same as the first kernel you configured. cd into /usr/src/linux and run make menuconfig

3.build your new kernel i think the command is make && make modules_install but i could be a little off.

4. copy your new kernel over to your boot partition. remember when you do this you can name your kernel anything. i ussually name mine after the purpose they where made for. for example i have 3 kernels right now, one for an ati graphics car so its called ATI, one for an nvidia card so its called NVIDIA, and one generic kernel for use with my built in graphics card called GENERIC.

5. add this new kernel as a second entry into your grub.conf and then test it by rebooting and selecting your new kernel.

if it boots then your good to go if not the maybe i didnt explain well enough. and im sorry. but im more than willing to personally help if you can get a hold of me. just send me a msg through the forums and ill msg you or something.
_________________
you never stop being a n00b till you code kernels. so dont talk down to people cause they probably know stuff you dont, or vice versa. ANYONE can be your friend
Back to top
View user's profile Send private message
Dillius
Tux's lil' helper
Tux's lil' helper


Joined: 12 Mar 2005
Posts: 119

PostPosted: Sat Mar 12, 2005 4:07 am    Post subject: using this Reply with quote

I am using Gentoo for my first time(moved over from mandrake), probably like the original poster. I'm not too confident in my kernel-compiling abilities either, but this post made me feel a bit better about it.

My main question is in regard to the ATI Radeon drivers. Is it possible to do all the configurations to the kernel needed as described this way? Therefore avoiding the need to completely reinstall Gentoo?

Also, does anyone know of a more detailed guide on kernel upgrading/replacing? Perhaps even detailing the ATI driver issue also?
Back to top
View user's profile Send private message
mno
Guru
Guru


Joined: 29 Dec 2003
Posts: 454
Location: Toronto, Canada

PostPosted: Thu Mar 17, 2005 4:52 am    Post subject: Reply with quote

Hey c0rax,

Thanks for the reply. I still have to go through with the procedure, and I'm a bit worried, but I will do it a bit later this week and post some more detailed steps for those looking to do this down the road. It seems anyone doing this had enough technical knowledge to never even blink, and the newbies found it better to reinstall the system with the new kernel rather than attempt it.

Thanks,
mno
_________________
"Hello and goodbye. As always." | You can't use   here?? | Unanswered
Back to top
View user's profile Send private message
mno
Guru
Guru


Joined: 29 Dec 2003
Posts: 454
Location: Toronto, Canada

PostPosted: Thu Mar 17, 2005 7:41 am    Post subject: Reply with quote

Hmm, seems there's a more detailed solution available in the Gentoo Wiki:

http://gentoo-wiki.com/HOWTO_Remote_Kernel_Upgrade
http://gentoo-wiki.com/HOWTO_Compile_a_Kernel_Manually

Probably would've been a good idea to search there, first. :oops:
_________________
"Hello and goodbye. As always." | You can't use   here?? | Unanswered
Back to top
View user's profile Send private message
Zuu
n00b
n00b


Joined: 22 Feb 2005
Posts: 25
Location: /home/sweden

PostPosted: Thu Mar 17, 2005 8:07 am    Post subject: Reply with quote

While I wrote this I did update my own kernel. So the exact versions might differ.


As root:
Code:
# emerge gentoo-dev-sources
# cd /usr/src/linux-2.6.10-gentoo-r6/


If you have an config file from anoter older 2.6.x kernel you can imort that counfig file:
Code:
# mount /boot
#cp /boot/config-2.6.9-gentoo-r1-scsi ./.config
#make oldconfig

else
Code:
# make menuconfig


Next step, compile the kernel
Code:
# make && make modules_install


Copy it to /boot (if you followed the avice in the Gentoo handbook it will be a seperate partiton, that is not automaticly mounted at boot)
Code:
# mount /boot
# cp arch/i386/boot/bzImage /boot/kernel-2.6.10-gentoo-r6
# cp System.map /boot/System.map-2.6.10-gentoo-r6
# cp .config /boot/config-2.6.10-r6


Code:
vi /boot/grub/grub.conf

and add after or before existing blocks of similar code:
Code:
title=Gentoo Linux 2.6.10-r6
        root(hd0,0)
        kernel /kernel-2.6.10-gentoo-r6 root=/dev/hda2

Note that /dev/hda2 is my root partition. If you're root partition is located somewhere else you have to change that.
Note2 that root(hd0,0) tells grub that the kernel is located on pratition 0 on disk 0. If that is not your case you'll have to change that.

--

Now there will come people that says that you should not compile the code as root, but copy the kernel source to your home directory, and compile it there as your limited user. However, I as being lazy don't do that.
Back to top
View user's profile Send private message
mno
Guru
Guru


Joined: 29 Dec 2003
Posts: 454
Location: Toronto, Canada

PostPosted: Thu Mar 24, 2005 1:01 am    Post subject: Reply with quote

Thanks for the step-by-step. A good continuation can be found in the wiki: http://gentoo-wiki.com/HOWTO_Remote_Kernel_Upgrade
_________________
"Hello and goodbye. As always." | You can't use   here?? | Unanswered
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Kernel & Hardware All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum