View previous topic :: View next topic |
Author |
Message |
blacke n00b
Joined: 17 Mar 2006 Posts: 2
|
Posted: Fri Mar 17, 2006 8:26 am Post subject: Wrong kernel folder is used for modules. [SOLVED] |
|
|
Doing an emerge of shfs renderd it unusable because it was placed in a different kernel module tree then the one i'm using. I have 2 kernel installed, 2.6.12-gentoo-r6 and 2.6.15-gentoo-r1. I am using 2.6.15 but the module of shfs was placed in the 2.6.12 module tree.
What can be done to fix this?
Last edited by blacke on Fri Mar 17, 2006 8:40 am; edited 1 time in total |
|
Back to top |
|
|
gimpel Advocate
Joined: 15 Oct 2004 Posts: 2720 Location: Munich, Bavaria
|
Posted: Fri Mar 17, 2006 8:34 am Post subject: |
|
|
you have to delete the symlink /usr/src/linux and create one to the kernel-source of the kernel you want the modules built for.
Code: | cd /usr/src && rm linux && ln -s linux-2.6.15-gentoo-r1 linux |
for example.
That way it is controlled what kernel external modules are built for.
HTH _________________ http://proaudio.tuxfamily.org/wiki - pro-audio software overlay
|
|
Back to top |
|
|
blacke n00b
Joined: 17 Mar 2006 Posts: 2
|
Posted: Fri Mar 17, 2006 8:40 am Post subject: |
|
|
Ahh, didn't occure to me that they used that linking. So used to manual source compailing and they use `uname -r`. |
|
Back to top |
|
|
stevyn n00b
Joined: 26 Aug 2004 Posts: 70 Location: USA
|
Posted: Fri Mar 17, 2006 4:38 pm Post subject: |
|
|
You can also add the "symlink" USE flag to your /etc/make.conf to automatically delete the old symlink and make the new one. Usually what I do when portage wants to upgrade the kernel is emerge the sources, go to /usr/src/[old kernel] and copy the .config file to /usr/src/linux. Then run "make menuconfig" to make sure everything works and run "make && make modules_install && make install"
make install is really convienent if you use grub. Then re-emerge any drivers like nvidia or wifi that you need as external modules.
Another tip is when you notice you have 10 old versions of the kernel sources in /usr/src is to run "emerge -pP [kernel-sources]" where [kernel-sources] is whatever kernel you're getting from portage. Mine happens to be ck-sources. This will prune the old kernels and leave the current one untouched. Although this process can be a bit slow. A trick I found was to actually delete the directories under /usr/src and then prune the kernels. This will make portage think only the correct kernel is there and deleting them manually is faster and it makes sure to get rid of all the uneeded files. |
|
Back to top |
|
|
|