Kernel source not found. (can't install network card drivers)
Linux - SoftwareThis forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.
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.
So, basically, you can't install the source because you can't get online, but you can't get online because you don't have the source?
Fun.
If you have access to portable media (flash drive, USB HDD, floppy, etc):
Copy your sources.list file (/etc/apt/sources.list) to your media.
Find a comp with internet access.
Find the url of the main repo from your sources.list file.
C&P into browser, find the kernel source files for your kernel.
I believe the kernel source packages go under the names "linux-headers-{version}-{type}". So you would want something similar to "linux-headers-2.6.18-5-686". Not exactly sure, maybe someone can verify?
Once you have the packages, put them on your media, transfer to linux comp, and install.
More information may be helpful. Could you post a) your sources.list file and b) the output of
Code:
aptitude search linux | grep ^i
If the aptitude command results in an error that you don't have it installed or something, then nevermind.
Also, if you're more competent at linux than your question sounded (you are a full 65 posts ahead of me, after all), and my post did not help at all, well...sorry 'bout that :>
Last edited by eternicode; 12-11-2007 at 02:04 AM.
Thanks for the advice; I'm dual booting right now.
I'm not sure what you're expecting but... here's my sources.list.
Code:
#
# deb cdrom:[Debian GNU/Linux 4.0 r1 _Etch_ - Official i386 CD Binary-1 20070819-11:52]/ etch contrib main
deb cdrom:[Debian GNU/Linux 4.0 r1 _Etch_ - Official i386 CD Binary-1 20070819-11:52]/ etch contrib main
# Line commented out by installer because it failed to verify:
#deb http://security.debian.org/ etch/updates main contrib
# Line commented out by installer because it failed to verify:
#deb-src http://security.debian.org/ etch/updates main contrib
And this:
Code:
compname:/home/username# aptitude search linux | grep ^i
i doc-linux-text - Linux HOWTOs and FAQs in ASCII format
i libselinux1 - SELinux shared libraries
i linux-image-2.6-686 - Linux kernel 2.6 image on PPro/Celeron/PIIi linux-image-2.6.18-5-686 - Linux 2.6.18 image on PPro/Celeron/PII/PIIih linux-kernel-headers - Linux Kernel Headers for development
i A linux-sound-base - base package for ALSA and OSS sound systemi python-selinux - Python bindings to SELinux shared librariei selinux-policy-refpolicy-target - Targeted variant of the SELinux reference
i util-linux - Miscellaneous system utilities
Thanks for any help...
Not sure where the repositories are or how to find out. I think it's already got the headers installed, so I'm assuming it might NOT be the same thing? I thought it was too though...
There is the package that matches what you said in your first post. How did you determine your kernel version to be 2.6.18-5?
The aptitude command listed all packages you have currently installed with the word "linux" in their name. According to that list, it looks like your kernel is linux-image-2.6-686; the corresponding headers package is linux-headers-2.6-686.
However, the latter package shows a dependency for the former package. If you're not afraid of having to do a fresh install if you mess something up (won't necessarily happen, but there's always the possibility), download the 2.6.18-5 header .deb (the "i386" link under the "Download" section), and start down Dependency Road. Basically, you'll have to come back and download/transfer/install any missing dependencies until the thing installs right.
The long way to do this would be to boot into etch and use
Code:
sudo apt-get install package.deb
Apt will likely spit out some junk about missing dependencies. Make note of these (on paper or something), and return to windows to download the dependent packages. You should be able to use the "Search package names" form at the top of the packages pages.
The short(er) way would be to click around on the listed dependencies for the package, download everything you don't have, then install the stuff through apt and hope you got everything. Either way, it's good learning experience
I had to go through this stuff with my Fedora 7 install before we had DSL. Though that was just for G++ to compile a dialup program...
Have fun, and post back if more info/help is needed!
Last edited by eternicode; 12-11-2007 at 03:34 AM.
No where on the internet says what to do... And I find it impossible to be the only person who's getting this. There's posts all over the net about the problem and not one single solution. Not one.
I'd love to know why it wasn't packaged with debian to begin with as obviously every single user will need it.
Anyway... how do I get kernel-source? It's not on the internet, and due to needing it to install my network card drivers, I can not download it via apt-get.
Sorry. All I've ever needed to compile stuff like this was the kernel-headers.
Anyway, for linux-source (which, admittedly, does seem to be different), try http://packages.debian.org/etch/linux-source-2.6.18 . I wasn't able to find a 2.6.18-5-686 version like with the headers, but hopefully that package will work for what you need. If not, there's a search box at the top right of that page, as well as links to related packages; check those out.
Also, "etch kernel source not found" on google turned up this thread: http://www.linuxquestions.org/questi...-found-268289/
Don't know if the threadstarter was specifically talking about etch, but the general idea of the solutions should be the same. Most of the early responses are for if your sources are already installed (which they may be). Have a read through that thread first. If that method turns nothing up, try the source deb from the packages site.
Good luck
Last edited by eternicode; 12-11-2007 at 12:09 PM.
That file wasn't installed, but it didn't make MUCH of a difference.
That thread is no help There are no such files on my cd, nor do they seem to exist on the internet. Consequently I can never obtain them until I have obtained them due to not having my network card work so I can just use apt-get.
How can no one have an answer to an inevitably common problem that pretty much EVERY new user who's NIC isn't instantly recognized by Linux get?
Or is that the kernel itself and not.. the source, or whatever.
Anyway, after installing the file you recommended above there was a minor difference:
Logged in NOT as root (changed user name in text to 'main'):
Code:
main@0x1:/files/network_drivers/l1-linux-v1.2.40.2$ cd src
main@0x1:/files/network_drivers/l1-linux-v1.2.40.2/src$ make install
Makefile:62: *** Linux kernel source not found. Stop.
main@0x1:/files/network_drivers/l1-linux-v1.2.40.2/src$ sudo make install
main is not in the sudoers file. This incident will be reported.
The final line wasn't what I got the first time. It gave me a warning saying I should know what I'm doing blah blah blah (I didn't copy it down because I never saw it again) and then asked me for my password.
I typed in my root password once. Then twice. Then I tried my 'main accounts' password.
Then it said "main is not in the sudoers file. This incident will be reported." and when I tried the command again I never got to retry my password (caps lock was not on, I did NOT type it in wrong). I restarted my computer and tried again, no luck.
Then I tried su, typed in password, tried running sudo make install and got Makefile:62: *** Linux kernel source not found. Stop. - although, I don't remember correctly and I should have wrote that down too, but it might of been 'Makefile:58l instead.
I'm getting seriously sick of having to switch OS each time I want to use the net for 5 seconds. Why wont someone just tell me which darn file I need : /
How can no one have an answer to an inevitably common problem that pretty much EVERY new user who's NIC isn't instantly recognized by Linux get?
Current Fedora and Ubuntu distros (among others) contain modern kernels that support the Attansic L1 NIC natively. Bottom line: You need a 2.6.21 or later kernel if you want to avoid the headache of building your own atl1 driver.
Sorry to bump an old thread, but I'm having the same problem here. Well, slightly different, but mostly similar.
I actually replaced the motherboard on a working and fully up-to-date Debian Etch system. The new motherboard has the Attansic L1 NIC on board which is not supported by the kernel. My kernel is 2.6.18-6-686 and I don't have the kernel sources installed on my machine. But before I even try to compile the driver, I do have one very big concern. Having to compile the driver against my current kernel version, does that mean that every time there's a kernel update, the driver stops working and I will have to recompile the driver?
I mean, there have been several kernel updates in a very short time (2.6.18-4-686 -> 2.6.18-5-686 -> 2.6.18-6-686).
does that mean that every time there's a kernel update, the driver stops working and I will have to recompile the driver?
Yes, that's exactly what it means. Very perceptive.
Because I'm not a Debian user, I don't know how to go about installing Debian's kernel source package. (I use a vanilla kernel under Fedora 8.) Surely though someone else here knows how to do it.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.