LinuxQuestions.org
Register a domain and help support LQ
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Hardware
User Name
Password
Linux - Hardware This forum is for Hardware issues.
Having trouble installing a piece of hardware? Want to know if that peripheral is compatible with Linux?

Notices

Reply
 
LinkBack Search this Thread
Old 12-15-2004, 09:28 PM   #1
Ben136
LQ Newbie
 
Registered: Dec 2004
Posts: 14

Rep: Reputation: 0
Unhappy Realtek 8139 not working on debian


Hi,

I have been using Linux for just under two days, and any help getting it up would be immensely appreciated! Using Debian 3.0r3 stable release, i386.

I have a standard HP computer with one PCI network card, RealTek RTL-8139. When I boot my Windows 2000 partition, it correctly shows the network card, gets an IP address from the router and I can surf the internet fine using the auto detected settings. So the card itself works.

During Debian's installation, it asks me to configure the network. DHCP fails as do manual settings. It can not get the network working. During boot-up it looks like it is loading the driver RTL8139.

modprobe -d eth0 says nothing.

If I type "ifconfig eth0 up" it says "SIOCSIOFFLAGS: Resource temporarily unavailable"

"ifconfig -a" does list an "eth0" with a hardware address and base address.

Any ideas on how to fix this?

I have been trying to get it to use 8139too. I have added it to the list of drivers to load during startup. "lsmod" shows it as loaded, and that it is used by "0".

In /etc/modules I have added a line that read:

8139too

In /etc/modutils/aliases I have added the line:

alias eth0 8139too

and ran update-modules

lspci also identifies the Ethernet controller as "Realtec Semiconductor Co. Ltd. RTL-8139 (rev 10)".

With this, if I type "ifconfig" it just lists information for lo.

If I type "ifconfig -a" then it list eth0, eth0 and lo. eth0 and eth1 are both shown as ethernet with the same hardware addresses. The base address for eth0 is 0x2400 and for eth1 it is 0x7000.
So I tried "ifconfig eth0 up", and it says "SIOCSIOFFLAGS: Resource temporarily unavailable"
So I tried "ifconfig eth0 down", no error.
If I type "ifconfig eth1 up" then I get "Device or resource busy".
I also tried "modprobe 8139too" which give no message.

Any thoughts?
How do I change 8139 to 8139too? 8139 does not appear to be listed anywhere and must be built in the kernal somehow? Or should I just see if I can get a more generic network card?
 
Old 12-16-2004, 04:04 AM   #2
acker
Member
 
Registered: Apr 2004
Location: Timisoara, Romania
Distribution: Debian
Posts: 90

Rep: Reputation: 15
hi

i am using debian too, but sarge. When i've installed Debian, I've instaled stable too. I do not quite remebmer if I had to install the module in install menu from the debian installer, but the network card worked for me.

Code:
modprobe -d 
modprobe: invalid option -- d
you could take a look here
http://64.233.183.104/search?q=cache...&hl=en&start=5

Quote:
I was seeing this error message with an eepro100, however > I was never able to ever get eth0 to come up. > > The problem was with an IRQ conflict, which was scrolling > by in the kernel initialisation - took me a while to spot that
also check this:
http://www.wplug.org/pipermail/wplug...il/012303.html

I've got the pretty much same output for lspci:
0000:00:0b.0 Ethernet controller: Realtek Semiconductor Co., Ltd. RTL-8139/8139C/8139C+ (rev 10)

Quote:
Hey, i got it !
It was really an IRQ problem, which coudn't be solved within Linux.- It was a wrong setting in the bios, which assigned IRQs automatically. Changing this options to manually and setting the irq with the tool that is coming with the ethernet-card worked.

The card is now recognized - there are no errors in dmesg.
losmod lists the driver rtl8139 as used=1
cat /proc/interrupts shows eth0 with IRQ3 (like assigned wth the tool), ifconfig lists eth0 and i'm able to ping the network and the internet.
Try to see what `dmesg` has to say about this too. Do you have 2 drivers for one card? I don't know why you have eth0 and eth1 if you've got one card...

I'll hope you'll understand something from the above links and quotes. If not, post again with dmesg output (related to network card)

-acker
 
Old 12-16-2004, 07:24 AM   #3
shoekstr
LQ Newbie
 
Registered: Aug 2003
Distribution: Gentoo, Debian, Slackware
Posts: 22

Rep: Reputation: 15
the 8139too module works for the Realtek 8139 cards what you have to do is assign a ip address to your card all you have to do is edit the config file /etc/network/interfaces file and have it look something like this for a static ip

auto eth0
iface eth0 inet static
address 192.168.0.10
netmask 255.255.255.0
network 192.168.0.0
broadcast 192.168.0.255
gateway 192.168.0.1


and put your isp's dns server in the /etc/resolv.conf so they look like the following

nameserver 172.25.188.66
nameserver 172.25.188.77

or if you on dhcp all you need in you /etc/network/interfaces file is

auto eth0
iface eth0 inet dhcp

once that is done you just restart the network by running the command /etc/init.d/networking restart

and you network should work
 
Old 12-16-2004, 06:07 PM   #4
Ben136
LQ Newbie
 
Registered: Dec 2004
Posts: 14

Original Poster
Rep: Reputation: 0
Do PIC network cards have IRQ's? I looked in my BIOS setupt and it does not appear that you can change or assign the IRQ. The Windows driver also does not show an IRQ. That is only for ISA cards, no?

I did not see anything during the boot, but it scrolls by so fast. Doesw it get captures anywhere? I googled about that, but no luck.
 
Old 12-16-2004, 06:28 PM   #5
Ben136
LQ Newbie
 
Registered: Dec 2004
Posts: 14

Original Poster
Rep: Reputation: 0
Cool

Ok, most likely the problem is with the IRQ. Sounds like if the network card is in the first slot (and mine is) then it will share the IRQ with the graphics card. Interesting, since Linux is not happy with both of those.

So maybe I just need to move the network card to a different PCI slot. Hmmmm... Will try first and let you know.

Thank you for all the great suggestions. I was surprized by how many serious replies I got and how quickly.

Maybe they will make a Linux convert out of me...!
 
Old 12-16-2004, 07:22 PM   #6
acker
Member
 
Registered: Apr 2004
Location: Timisoara, Romania
Distribution: Debian
Posts: 90

Rep: Reputation: 15
Quote:
Originally posted by Ben136
Do PIC network cards have IRQ's? I looked in my BIOS setupt and it does not appear that you can change or assign the IRQ. The Windows driver also does not show an IRQ. That is only for ISA cards, no?

I did not see anything during the boot, but it scrolls by so fast. Doesw it get captures anywhere? I googled about that, but no luck.
Yes, PCI cards have IRQ, but most of the cards are PnP (Plug and Work ). I don't think that switching from one slot to another would help, but you can give it a try.
To see messages during boot you can use:
Code:
dmesg
or
Code:
dmesg | less
If it complains about less you could use "more" instead of "less". But you should definetly install less too.

What kernel do you use? 2.2, 2.4 ?
Keep us posted...

--acker
 
Old 12-16-2004, 08:57 PM   #7
Ben136
LQ Newbie
 
Registered: Dec 2004
Posts: 14

Original Poster
Rep: Reputation: 0
Ok, moving the network card to a different slow makes no difference. Still works on Windows, Debian install can't get the network to work. Tried a different network card from a friend, but it was not recognized at all.

Typing cat /proc/interrupts does not show anything ethernet related.

ifconfig eth0 up still says the resource is temporarily unavailable.

dmesg says that it rtl8139.c. It list eth0, at 0x2400, IRQ 0, 00:40:f4:51:63:a2

Is that IRQ0 a problem?

/etc/network/interfaces had the typical static onfig info in it, so I changed it to DHCP.

Typing "/etc/init.d/networking restart" just says the resource is temporarily unavailable.

Any thoughts?
 
Old 12-16-2004, 10:36 PM   #8
shoekstr
LQ Newbie
 
Registered: Aug 2003
Distribution: Gentoo, Debian, Slackware
Posts: 22

Rep: Reputation: 15
Which kernel are you using use uname -a and you should get a kernel version mine is 2.6.8-1-386 I have no problem with the realtek drivers on any of my cards

What is the auctual make of your network card like dlink or 3com?
 
Old 12-17-2004, 06:28 AM   #9
McCloud
Member
 
Registered: Sep 2004
Distribution: Debian Etch
Posts: 179

Rep: Reputation: 30
First of all, remove the 8139too line from your '/etc/modules' file. Specifying the 'alias eth0 8139too' in /etc/modutils/aliases' is sufficient for the kernel to load the module.

Second, do you have 1 or 2 network cards. I think you have one card, so why do you have an eth0 AND eth1 listed??? Check your '/etc/network/interfaces' file.

Third, can you post the output of dmesg, lspci and ifconfig (so, the complete output, not telling us what 'some' lines say), this will make it easier to debug.

I have an onboard Realtek 8139 myself (using Debian Sarge, kernel 2.4.27) and it works perfectly, no problems at all.

Good luck.
 
Old 12-17-2004, 07:00 AM   #10
daYz
Member
 
Registered: Nov 2003
Distribution: Debian
Posts: 164

Rep: Reputation: 30
It seems to me the right module was not loaded. Are you sure this card needs the 8139 or the 8139too module? You can use http://www.google.com to quickly see if this is true. I think I had a 8139 card and needed to load the ne module, but I am not sure.
Or maybe load the 8139cp module.

Google is the first best help for linux questions. Most questions already have been asked and solved before, so you can quickly find a solution this way.
 
Old 12-17-2004, 07:05 PM   #11
Ben136
LQ Newbie
 
Registered: Dec 2004
Posts: 14

Original Poster
Rep: Reputation: 0
i am using Debain 3.0r3 (the latest stable release). But perhaps it is too old? I could always torrent the latest version and test that.

Yes, the network card is definitely Realtek 8139, says so in the booklet and is also how Windows identifies it.

However, I found an old 3COM 10MBit card. Maybe I shall try that tonight...

This is very frustrating. If eth0 tells you the resource is temporarily unavailable, it should at least say why... What good is that?
 
Old 12-17-2004, 08:13 PM   #12
McCloud
Member
 
Registered: Sep 2004
Distribution: Debian Etch
Posts: 179

Rep: Reputation: 30
I don't mean to be a pain in the ass, but did you read my post????

I asked for information (dmesg, lspci and other things). I've got a Realtek 8139 integrated on my MB and it works perfectly (Debian Sarge, netinstall. I installed it using a Woody net-install, so my NIC works in Woody).

These Realtek cards do work in Debian (actually it has nothing to do with the distribution, but with the kernel).

I'd like to help you to work this out, so please post some relevant information so I can try to see what's wrong. I've got almost the same setup as you, so I think we can fix this problem.
 
Old 12-17-2004, 09:04 PM   #13
Ben136
LQ Newbie
 
Registered: Dec 2004
Posts: 14

Original Poster
Rep: Reputation: 0
Talking

I would like to thank you all for your posts! Being new to Linux, I hot the latest stable Debian release and just installed the "safe" Debian option. However, after reading your emails again, I thought, ok, I would try the bf24 install option. (I should have tried it earlier, but the original one did pick up the network card etc. so I thought it ought to have worked.)

And now its happy! Auto detected and auto configured the RealTek 8139 card all by itself (says so during the boot). The install is right now happily running on my other PC and is currently auto downloading updates.

Happy happy joy joy joy!
Happy happy joy joy joy!
Happy happy joy joy joy!

THANK YOU ALL SO VERY MUCH!! The amount of sincere serious help in the posts above is really very encouraging.

One question, being new to Linux, I chose Debian because it comes bundles with lots of goodies and has high ease of use. But I could still switch to another one (Red Hat?) if that would be better?

Also, should I consider torrenting the latest Debian build, even if not stable? I guess you can update from Linux itself now, so I can play with that at some point.

Again, thank you for all your help and kind indulgence.
 
Old 12-17-2004, 09:14 PM   #14
McCloud
Member
 
Registered: Sep 2004
Distribution: Debian Etch
Posts: 179

Rep: Reputation: 30
Well, I have been a Linux user for over 3 years (on and off). I started with Mandrake (I didn't like it, too much GUI configuration stuff which conflicted with my own settings. This was Mandrake 8 I think), switched to Red Hat (which I liked better then Mandrake). Then my colleagues at work were all using Debian, and they were saying how cool 'apt-get' and Debian packages were. I figured "What the hell!" and installed Debian in March of this year. I'm really glad I did, the package management is superb, there's a lot of info on the net about Debian. I'm really happy with this distribution. I completely switched to Linux because of this distribution. I only use Windows for games and audio-cd copying (unfortunately, Exact Audio Copy doesn't wokl that well on Linux, and I haven't found a Linux program yet that matches EAC).

I use the 'Testing' (Sarge) version of Debian. It's really stable and you get all the new applications. If you want to upgrade to Sarge, just adjust your '/etc/apt/sources.list' to point to the Sarge version and do a 'apt-get update' followed by a 'apt-get dist-upgrade'.

Good luck with Debian.
 
Old 12-18-2004, 01:42 AM   #15
Ben136
LQ Newbie
 
Registered: Dec 2004
Posts: 14

Original Poster
Rep: Reputation: 0
Cool

Thank you. I shall have a look at Sarge.

Tonight I also managed to fix my Gnome desktop, get Apache and PHP etc all working.
So I am really feeling good about Debian right now!
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Not able to get my Realtek 8139 to work in Debian 3.1 jhire70 Linux - Hardware 10 10-25-2005 06:42 PM
eth0 not working on realtek 8139 gregorya Linux - Networking 9 03-12-2005 12:46 PM
Realtek 8139 not recognized on debian bwaters Linux - Hardware 0 11-13-2004 10:30 AM
Realtek 8139 and Debian Sarge turbulence Linux - Networking 1 10-25-2004 08:42 AM
Network with Debian Woody and Realtek 8139 grcbheax Linux - Networking 2 08-09-2004 10:10 AM


All times are GMT -5. The time now is 09:07 AM.

Main Menu
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration