LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Networking (https://www.linuxquestions.org/questions/linux-networking-3/)
-   -   eth0: ERROR while getting interface flags: No such device (https://www.linuxquestions.org/questions/linux-networking-3/eth0-error-while-getting-interface-flags-no-such-device-589899/)

ncsuapex 10-06-2007 11:57 AM

eth0: ERROR while getting interface flags: No such device
 
I just purchased a new barebones PC and took the HD out of my old PC and put it in this new barebones one. I am having problems getting the network working. Below are commands with responses that Ive tried for trouble shooting.

I am running Slackware with the 2.6.13 kernel
I had to disable acpi (acpi=off) for it to bootup, it was hanging on IRQ#9 disabling. I am using lilo.



PC is this one: http://www.tigerdirect.com/applicati...33209&CatId=31



I'm not so sure that some of the results are "new" results, or left over from the previous PC. Any way I can force linux to recheck for hardware to see if that is the right chipset for the network card?


I ran netconfig and entered all the information and got no errors.




dmesg | grep -i net
NET: Registered protocol family 16
NET: Registered protocol family 2
Initializing IPsec netlink socket
NET: Registered protocol family 1
NET: Registered protocol family 17
NET: Registered protocol family 10



lspci | grep -i ethernet
01:00.0 Ethernet controller: Realtek Semiconductor Co., Ltd.: Unknown device 8136 (rev 01)

/sys/bus/pci/devices/0000:01:00.0# cat device
0x8136


ifconfig eth0 up
eth0: ERROR while getting interface flags: No such device


uname -a
Linux "my hostname" 2.6.13 #1 Sat Sep 3 21:11:20 PDT 2005 i686 pentium4 i386 GNU/Linux


01:00.0 Ethernet controller: Realtek Semiconductor Co., Ltd.: Unknown device 8136 (rev 01)
Subsystem: Intel Corporation: Unknown device d607
Flags: bus master, fast devsel, latency 0, IRQ 11
I/O ports at 1000 [size=256]
Memory at 50000000 (64-bit, non-prefetchable) [size=4K]
Expansion ROM at 50200000 [disabled] [size=128K]
Capabilities: [40] Power Management version 2
Capabilities: [48] Vital Product Data
Capabilities: [50] Message Signalled Interrupts: 64bit+ Queue=0/1 Enable-
Capabilities: [60] #10 [0001]
Capabilities: [84] #09 [014c]

osor 10-06-2007 12:02 PM

Is the correct module loaded (what does lsmod say)?

ncsuapex 10-06-2007 12:10 PM

I didn't see anything that looked like a network module loaded when I ran lsmod. And I'm not real sure which module needs to be loaded. I've seen


From http://www.xpcgear.com/d945gcpe.html

10/100 Mbits/sec LAN subsystem using the Realtek* RTL8101E-GR Ethernet LAN controller


from intel's website.


"The board provides one of the following:
Gigabit (10/100/1000 Mbits/sec) LAN subsystem using the Intel® 82573L Gigabit Ethernet Controller
10/100 Mbits/sec LAN subsystem using the Intel® 82562GZ Platform LAN Connect (PLC) device"

ncsuapex 10-08-2007 05:41 PM

ok I did

modprobe r8169

when I do lsmod I get

Module size used by
r8169 23304 0


but when i try to do ifconfig eth0 up I get the error

eth0: error while getting interface flags: No such device


ifconfig -a doesnt show eth0 at all

osor 10-08-2007 06:18 PM

Quote:

Originally Posted by ncsuapex (Post 2917692)
modprobe r8169

For the Realtek FastEthernet controller (which seems to be what you have from your lspci) try the modules for 8139cp or 8139too. If you somehow have the Intel controller, try e100 or e1000 for FastEthernet or Gigabit ethernet respectively. When you find the correct driver, you can add it to modules.conf or whatever.

ncsuapex 10-09-2007 09:47 AM

I ended up adding the modules 8139cp and 8139too still no worky. I did a modules -l | grep for 100 and didn't see either of those 2 modules.


Is it possible that the lspci and other commands are giving data about my old PCI ethernet card? All I did was take the harddrive out of one PC and put it into a new PC. Is there a way to force linux to probe the new hardware to see what it says?


thanks for the replies so far.


j

osor 10-09-2007 10:51 AM

Quote:

Originally Posted by ncsuapex (Post 2918430)
I did a modules -l | grep for 100 and didn't see either of those 2 modules.

That just means you (or whoever compiled your kernel) didn’t build them.
Quote:

Originally Posted by ncsuapex (Post 2918430)
Is it possible that the lspci and other commands are giving data about my old PCI ethernet card?

I don’t think so. Generally, lspci gets its data from the sysfs interface provided by the kernel. This is dynamically generated at boot from hardware probing.

An alternate theory is that you may have the NIC disabled in the BIOS or something.

ncsuapex 10-09-2007 01:12 PM

I went back and checked for the e100 module and it was there so I added it along with the 8139cp and 8139too and r8169, no worky. I checked in the BIOS and it had On board LAN: enabled.


I'm thinking about just putting in my old PCI network card that was in the old PC and see if that works.

osor 10-09-2007 04:57 PM

Quote:

Originally Posted by ncsuapex (Post 2918638)
I'm thinking about just putting in my old PCI network card that was in the old PC and see if that works.

I guess that’s what you do when you’re out of ideas. You might instead try to boot a livecd that has good autodetection and that has a more recent kernel (such as knoppix). From there, see what module is being used for your NIC, and see if it works on your slack setup.

ncsuapex 10-09-2007 05:18 PM

I had booted with a Slax 5.1.8rc CD and it didn't detect it either. I think I have an old Knoppix CD laying around.. I might try that as well. The old Ethernet card was onboard as well so I can't take it out.


I did try to install the Realtek drivers

r8101-1.003.00.tar.bz2
Linux driver for kernel 2.6.x (Support x86 and x64)
http://152.104.125.41/downloads/down...1E/RTL8102E-GR


got this error. The "make clean modules" command was from the readme file, ran as root.


make clean modules
make -C src/ clean
make[1]: Entering directory `/installs/r8101-1.003.00/src'
rm -rf *.o *.ko *~ core* .dep* .*.d .*.cmd *.mod.c *.a *.s .*.flags .tmp_versions Module.symvers
make[1]: Leaving directory `/installs/r8101-1.003.00/src'
make -C src/ modules
make[1]: Entering directory `/installs/r8101-1.003.00/src'
make -C /lib/modules/2.6.13/build SUBDIRS=/installs/r8101-1.003.00/src modules
make: Entering an unknown directory
make: *** /lib/modules/2.6.13/build: No such file or directory. Stop.
make: Leaving an unknown directory
make[1]: *** [modules] Error 2
make[1]: Leaving directory `/installs/r8101-1.003.00/src'
make: *** [modules] Error 2



ls -l /lib/modules/2.6.13
total 1108
lrwxrwxrwx 1 root root 21 2006-06-25 19:29 build -> /usr/src/linux-2.6.13



ls /usr/src/
linux@ linux-2.4.32/ rpm/ slackbuilds/ speakup-2.4.32/

rsashok 10-09-2007 07:13 PM

You have version mismatch: your kernel version is 2.4.xx, but the drivers require version kernle 2.6.xx. I'd try drivers for 2.4.x

osor 10-09-2007 10:11 PM

Quote:

Originally Posted by rsashok (Post 2919019)
You have version mismatch: your kernel version is 2.4.xx, but the drivers require version kernle 2.6.xx. I'd try drivers for 2.4.x

Or maybe he is running 2.6.xx, but he has deleted his buildtree. Or perhaps he installed a precompiled kernel. If he didn’t build his currently-running kernel, he won’t be able to build modules for it.

ncsuapex 10-10-2007 11:03 AM

according to uname I am running 2.6.13. I installed Slackware 10.2 straight from the install CDs and havent modified the kernel at all. I don't remember deleting the build tree, but then again I'm not exactly sure what that is. How do I get it back?

uname -a
Linux "my hostname" 2.6.13

rsashok 10-10-2007 11:33 AM

Could you look at :
> ls -l /lib/modules
and
> ls -l /usr/src/kernels

osor 10-10-2007 12:36 PM

Quote:

Originally Posted by ncsuapex (Post 2919809)
I don't remember deleting the build tree, but then again I'm not exactly sure what that is. How do I get it back?

uname -a
Linux "my hostname" 2.6.13

The buildtree contains the configuration, Kbuild system, and object files for the kernel that you built. The sourcetree contains the sources that led to said object files. For a running kernel, the buildtree and sourcetree are usually accessed through the symlinks:
Code:

/lib/modules/`uname -r`/build
/lib/modules/`uname -r`/source

These almost always point to the same directory, which usually resides somewhere in /usr/src.

ncsuapex 10-10-2007 12:40 PM

ls -l /lib/modules
total 12
drwxr-xr-x 4 root root 4096 2006-05-22 19:55 2.4.31/
drwxr-xr-x 4 root root 4096 2006-05-20 18:48 2.4.32/
drwxr-xr-x 4 root root 4096 2007-10-09 15:45 2.6.13/


ls -l /usr/src/kernels
/bin/ls: /usr/src/kernels: No such file or directory

ls -l /usr/src/
total 16
lrwxrwxrwx 1 root root 12 2006-05-20 18:52 linux -> linux-2.4.32/
drwxr-xr-x 15 root root 4096 2006-08-21 13:03 linux-2.4.32/
drwxr-xr-x 7 root root 4096 2003-10-29 01:08 rpm/
drwxr-xr-x 4 root root 4096 2006-09-17 21:55 slackbuilds/
drwxr-xr-x 2 root root 4096 2005-12-04 17:35 speakup-2.4.32/

rsashok 10-10-2007 12:54 PM

It looks like a problem: there is no "linux-2.6.13" in your kernel source directory. Since you are running kernel version 2.6.13, I'd recommend installing sources for this version. It might be a good experience configuring and compiling your own kernel.

ncsuapex 10-10-2007 01:36 PM

ugh, I was waiting to hear those words. lol

Ive actually done a kernel rebuild a few years back on a RH system. You're probably right though, I should rebuild the kernel and do it the right way. I put in an old NIC I had on another PC and it recognized it. For now this will work and when I get the time/motivation to rebuild the kernel I will. Thanks for all the help/advice you guys gave me.

ncsuapex 03-16-2008 03:58 PM

back to this again.

I installed centos 5 and still can not get this card to work.

I did a modprobe on
8139cp 8139too and r8169

When I go into system-config-network it will not find the ethernet device.

any suggestions??

thanks



01:00.0 Ethernet controller: Realtek Semiconductor Co., Ltd. RTL8101E PCI Express Fast Ethernet controller (rev 01)


01:00.0 Ethernet controller: Realtek Semiconductor Co., Ltd. RTL8101E PCI Express Fast Ethernet controller (rev 01)
Subsystem: Intel Corporation Unknown device d607
Flags: bus master, fast devsel, latency 0, IRQ 11
I/O ports at 1000 [size=256]
Memory at 50100000 (64-bit, non-prefetchable) [size=4K]
Expansion ROM at 50300000 [disabled] [size=128K]
Capabilities: [40] Power Management version 2
Capabilities: [48] Vital Product Data
Capabilities: [50] Message Signalled Interrupts: 64bit+ Queue=0/1 Enable-
Capabilities: [60] Express Endpoint IRQ 0
Capabilities: [84] Vendor Specific Information



uname -r
2.6.18-53.el5xen



ls -l /lib/modules
total 16
drwxr-xr-x 6 root root 4096 Mar 16 11:35 2.6.18-53.el5
drwxr-xr-x 6 root root 4096 Mar 16 12:23 2.6.18-53.el5xen


dmesg | grep -i net
NET: Registered protocol family 16
NetLabel: Initializing
NetLabel: domain hash size = 128
NetLabel: protocols = UNLABELED CIPSOv4
NetLabel: unlabeled traffic allowed by default
NET: Registered protocol family 2
audit: initializing netlink socket (disabled)
SELinux: Registering netfilter hooks
Initializing IPsec netlink socket
NET: Registered protocol family 1
NET: Registered protocol family 17
SELinux: Unregistering netfilter hooks
NET: Registered protocol family 10
ip6_tables: (C) 2000-2006 Netfilter Core Team
ip_tables: (C) 2000-2006 Netfilter Core Team
Netfilter messages via NETLINK v0.30.
process `sysctl' is using deprecated sysctl (syscall) net.ipv6.neigh.lo.retrans_time; Use net.ipv6.neigh.lo.retrans_time_ms instead.
8139too Fast Ethernet driver 0.9.27
NET: Registered protocol family 31


lsmod
Module Size Used by
vfat 15809 1
fat 51165 1 vfat
i915 23873 2
drm 67029 3 i915
netloop 10945 0
netbk 78017 0 [permanent]
blktap 115813 2 [permanent]
blkbk 21985 0 [permanent]
ipt_MASQUERADE 7745 1
iptable_nat 11205 1
ip_nat 21101 2 ipt_MASQUERADE,iptable_nat
bridge 53725 0
autofs4 24389 2
hidp 23105 2
rfcomm 42457 0
l2cap 29633 10 hidp,rfcomm
bluetooth 53925 5 hidp,rfcomm,l2cap
sunrpc 144253 1
8139too 29121 0
mii 9409 1 8139too
ip_conntrack_netbios_ns 6977 0
ipt_REJECT 9537 3
xt_state 6209 9
ip_conntrack 53025 5 ipt_MASQUERADE,iptable_nat,ip_nat,ip_conntrack_netbios_ns,xt_state
nfnetlink 10713 2 ip_nat,ip_conntrack
iptable_filter 7105 1
ip_tables 17029 2 iptable_nat,iptable_filter
ip6t_REJECT 9409 1
xt_tcpudp 7105 26
ip6table_filter 6849 1
ip6_tables 18181 1 ip6table_filter
x_tables 17349 8 ipt_MASQUERADE,iptable_nat,ipt_REJECT,xt_state,ip_tables,ip6t_REJECT,xt_tcpudp,ip6_tables
dm_mirror 28997 0
dm_multipath 21577 0
dm_mod 58457 2 dm_mirror,dm_multipath
video 19269 0
sbs 18533 0
backlight 10049 0
i2c_ec 9025 1 sbs
button 10705 0
battery 13637 0
asus_acpi 19288 0
ac 9157 0
ipv6 251521 21 ip6t_REJECT
sr_mod 19941 0
sg 36061 0
parport_pc 29157 0
lp 15849 0
parport 37641 2 parport_pc,lp
snd_hda_intel 23897 0
snd_hda_codec 202689 1 snd_hda_intel
snd_seq_dummy 7877 0
snd_seq_oss 32577 0
snd_seq_midi_event 11073 1 snd_seq_oss
snd_seq 49841 5 snd_seq_dummy,snd_seq_oss,snd_seq_midi_event
snd_seq_device 11725 3 snd_seq_dummy,snd_seq_oss,snd_seq
snd_pcm_oss 43201 0
snd_mixer_oss 19009 1 snd_pcm_oss
usb_storage 76833 1
snd_pcm 72517 3 snd_hda_intel,snd_hda_codec,snd_pcm_oss
snd_timer 24773 2 snd_seq,snd_pcm
snd 52549 9 snd_hda_intel,snd_hda_codec,snd_seq_oss,snd_seq,snd_seq_device,snd_pcm_oss,snd_mixer_oss,snd_pcm,snd _timer
soundcore 11553 1 snd
ide_cd 40033 0
i2c_i801 11469 0
snd_page_alloc 13769 2 snd_hda_intel,snd_pcm
serial_core 23617 0
i2c_core 23745 2 i2c_ec,i2c_i801
cdrom 36705 2 sr_mod,ide_cd
serio_raw 10693 0
pcspkr 7105 0
ata_piix 18501 0
libata 116473 1 ata_piix
sd_mod 24897 2
scsi_mod 132941 5 sr_mod,sg,usb_storage,libata,sd_mod
ext3 123336 3
jbd 56553 1 ext3
ehci_hcd 33357 0
ohci_hcd 23645 0
uhci_hcd 25677 0



139cp: 10/100 PCI Ethernet driver v1.2 (Mar 22, 2004)

ncsuapex 03-17-2008 11:47 AM

*SOLVED*

found this thread

http://www.centos.org/modules/newbb/...13089&forum=39


Quote:

Please do the following
wget http://dag.wieers.com/rpm/packages/d....rf.noarch.rpm
rpm -Uvh --oldpackage dkms-r1000-1.05-1.nodist.rf.noarch.rpm


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