Linux - NewbieThis Linux forum is for members that are new to Linux.
Just starting out and have a question?
If it is not in the man pages or the how-to's this is the place!
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
I'm trying to install a wireless driver in Mandrake 10.1, but to do so I need the kernel source, and it wasn't included in the Mandrake 3-Cd install. I tried downloading the source tarball from kernel.org (my kernel here is 2.6.8.1) but once I unpacked it, it appeared that the whole kernel was there, waiting to be installed, whereas I just needed the source. I tried moving the directory the tarball created (linux-2.6.8.1) into /usr/src, but that didn't solve the problem. So is there any way to get just the source and create a directory for it in /usr/src? I'm also wondering if there's any difference between the source for linux-2.6.8.1 and the 2.6.8.1-12mdk kernel that's specific to Mandrake? I went to their web site and did a google search, but I couldn't seem to find that either.
Any help much appreciated. Please excuse my newbieness
Originally posted by batard I'm trying to install a wireless driver in Mandrake 10.1, but to do so I need the kernel source, and it wasn't included in the Mandrake 3-Cd install. I tried downloading the source tarball from kernel.org (my kernel here is 2.6.8.1) but once I unpacked it, it appeared that the whole kernel was there, waiting to be installed, whereas I just needed the source. I tried moving the directory the tarball created (linux-2.6.8.1) into /usr/src, but that didn't solve the problem. So is there any way to get just the source and create a directory for it in /usr/src? I'm also wondering if there's any difference between the source for linux-2.6.8.1 and the 2.6.8.1-12mdk kernel that's specific to Mandrake? I went to their web site and did a google search, but I couldn't seem to find that either.
Any help much appreciated. Please excuse my newbieness
Are you talking about the patch so it will update? Thats at kernel.org unless the mandrake ftp site doesn't have it. You can also check the planetmirror link below too.
Are you talking about the patch so it will update?
Not exactly. At least, I don't think so. Basically, I unpack the wireless driver I'm trying to install (it's a CVS archive), and then I go to install it and it asks for the kernel source. the Driver itself consists of three modules that I have successfully applied to the kernel in FC3 in the past (my FC3 has the source installed).
So I type ...
# cd madwifi
# make
Then it gives me an error that says to specify a KERNELPATH. So I say, OK, I should read up on this. So I read the readme that comes with the driver, and it says if it asks for a KERNELPATH, either make that into an environment variable or specify its path after # make. So I assumed that I would have kernel source in /usr/src/linux-2.6.8.1-12mdk. But there was no such thing. I tried anyway, typing
# make KERNELPATH=/usr/src/linux-2.6.8.1-12mdk
and
# make KERNELPATH=/lib/modules/2.6.8.1-12mdk/
both without any success. There is only one thing in /usr/src, and that's a directory called ATI, created when I installed an ATI driver. This just seems odd to me, coming from FC3.
Why don't you try to move your unpacked kernel into the /usr/src/linux-2.6.8-1 and then define it as an environment variable?
I assume it didn't work because your KERNELPATH was pointing to a non existent folder.
Why don't you try to move your unpacked kernel into the /usr/src/linux-2.6.8-1 and then define it as an environment variable?
Yes, unfortunately, I did try that and it didn't work. I forgot to mention that in the earlier post. I'm thinking of trying to recompile the kernel in the hope that it installs the source when it does that. I'm a little antsy about trying that - I've never done anything like that - but I can format and reinstall mandrake if necessary.
I'm assuming you will use the kernel sources from kernel.org. Then, you don't need to format and reinstall if the compile goes wrong. Just don't delete the old kernel image and the entry in the bootloader. This way you can always boot back with the old kernel and recompile untill you get it working.
One thing though, compiling a kernel won't install the sources, that must be done by you by extracting the kernel-source tarball into /usr/src/linux-kernel_version (if it doesn't exist, create it).
And compiling a kernel isn't that hard, even though it looks scary. Just use your common-sense for setting most of the options during the config stage, then go ahead and make bzImage, make modules, make modules_install, copy the kernel image, add the new kernel entry in the bootloader's config file and that should be it.
You can always post your doubts and questions here if you're not satisfied with something.
Also, take a look here: http://www.linuxquestions.org/questi...threadid=73436 it's fairly understandable written and may give you a start.
Good luck!
you need the mandrake kernel-source rpm for the kernel you are running. try to use urpmi to get it.
the problem you will run into with the kernel.org sources is if mandrake applied patches to the kernel source ( highly likely this is the case), then the kernel.org sources will not help you unless you know exactly what patches are added, and patch the vanilla sources with those packages. you basically have two choices:
either find the kernel-source package for your distro
or compile a new kernel. note that if you compile a new kernel, don't move the sources to /usr/src - this is no longer required and advised against by the kernel team.
Thanks for the guidance. I did what you suggested and actually discovered that the kernel source is located on CD 3 of the mandrake 10.1 CD set. I followed the directions posted here: http://www.speculation.org/garrick/kernelprep.html. I used urpmi, and kept to the directions to the last detail, because almost all of the commands there are unfamiliar. Then I went to install the madwifi driver, and I got a ton of errors about variables already being defined (and I mean a TON of errors). Both # make and # make install gave me trouble and quit out before finishing. I don't have the faintest idea what's going on here...
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.