LinuxQuestions.org
Visit Jeremy's Blog.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This 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


Reply
  Search this Thread
Old 03-31-2013, 12:52 PM   #1
M4trixSh4d0w
LQ Newbie
 
Registered: Mar 2013
Posts: 14

Rep: Reputation: Disabled
Not detecting ethernet connection on Debian


Hi, I have recently gotten a computer installed with Debian and I can't seem to get it to connect to the internet. I've tried ifconfig eth0, but that says it doesn't have any device, but ifconfig eth1 and eth2 show up but don't connect. I've also tried to ping google.com, but it returns unknown host. Maybe it doesn't have the software needed to use the ethernet ports?

Thanks
 
Old 03-31-2013, 01:00 PM   #2
spiky0011
Senior Member
 
Registered: Jan 2011
Location: PLANET-SPIKE
Distribution: /LFS/Centos6.3/Debian
Posts: 2,127
Blog Entries: 1

Rep: Reputation: 316Reputation: 316Reputation: 316Reputation: 316
Hi

How have you connected to the internet? via a router? if so try pinging the router
Code:
ping 192.168.0.1
 
Old 03-31-2013, 03:46 PM   #3
Lydia
LQ Newbie
 
Registered: Mar 2013
Posts: 3

Rep: Reputation: Disabled
M4trixSh4d0w,

Can you please post ifconfig -a

Are you using dhcp?
 
Old 03-31-2013, 06:09 PM   #4
M4trixSh4d0w
LQ Newbie
 
Registered: Mar 2013
Posts: 14

Original Poster
Rep: Reputation: Disabled
No, I'm not connected to the router, my router is actually 192.168.1.1, and it doesn't receive any response so linux doesn't even think I have connected my ethernet cord yet, but it does say that is has the right hardware in network devices.

I don't know if i'm using dchp, I don't think I did anything in particular to make it use dhcp.

ifconfig -a (without cord plugged in)
Code:
/home/m4trixsh4d0w# ifconfig -a
eth1      Link encap:Ethernet  HWaddr 00:50:45:5d:1a:f7  
          BROADCAST MULTICAST  MTU:1500  Metric:1
          RX packets:0 errors:0 dropped:0 overruns:0 frame:0
          TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000 
          RX bytes:0 (0.0 B)  TX bytes:0 (0.0 B)
          Interrupt:27 

eth2      Link encap:Ethernet  HWaddr 00:50:45:5d:1a:f6  
          BROADCAST MULTICAST  MTU:1500  Metric:1
          RX packets:0 errors:0 dropped:0 overruns:0 frame:0
          TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000 
          RX bytes:0 (0.0 B)  TX bytes:0 (0.0 B)
          Interrupt:27 

lo        Link encap:Local Loopback  
          inet addr:127.0.0.1  Mask:255.0.0.0
          inet6 addr: ::1/128 Scope:Host
          UP LOOPBACK RUNNING  MTU:16436  Metric:1
          RX packets:150 errors:0 dropped:0 overruns:0 frame:0
          TX packets:150 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:0 
          RX bytes:23517 (22.9 KiB)  TX bytes:23517 (22.9 KiB)
ifconfig -a (with cord plugged in)
Code:
/home/m4trixsh4d0w# ifconfig -a
eth1      Link encap:Ethernet  HWaddr 00:50:45:5d:1a:f7  
          BROADCAST MULTICAST  MTU:1500  Metric:1
          RX packets:0 errors:0 dropped:0 overruns:0 frame:0
          TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000 
          RX bytes:0 (0.0 B)  TX bytes:0 (0.0 B)
          Interrupt:27 

eth2      Link encap:Ethernet  HWaddr 00:50:45:5d:1a:f6  
          BROADCAST MULTICAST  MTU:1500  Metric:1
          RX packets:0 errors:0 dropped:0 overruns:0 frame:0
          TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000 
          RX bytes:0 (0.0 B)  TX bytes:0 (0.0 B)
          Interrupt:27 

lo        Link encap:Local Loopback  
          inet addr:127.0.0.1  Mask:255.0.0.0
          inet6 addr: ::1/128 Scope:Host
          UP LOOPBACK RUNNING  MTU:16436  Metric:1
          RX packets:160 errors:0 dropped:0 overruns:0 frame:0
          TX packets:160 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:0 
          RX bytes:24917 (24.3 KiB)  TX bytes:24917 (24.3 KiB)
There really isn't any difference if the cord is plugged in or not. The machine doesn't detect that I have plugged it into the ethernet port.

Last edited by M4trixSh4d0w; 03-31-2013 at 06:10 PM. Reason: Added Stuff
 
Old 03-31-2013, 09:05 PM   #5
M4trixSh4d0w
LQ Newbie
 
Registered: Mar 2013
Posts: 14

Original Poster
Rep: Reputation: Disabled
bump?
 
Old 03-31-2013, 09:17 PM   #6
descendant_command
Senior Member
 
Registered: Mar 2012
Posts: 1,385

Rep: Reputation: 354Reputation: 354Reputation: 354Reputation: 354
What is the Ethernet device(s)?
Post output of 'lspci -k'
Look at wiki.debian.org for any special instructions for your device(s).
 
Old 03-31-2013, 09:38 PM   #7
etech3
Senior Member
 
Registered: Jul 2009
Location: Virginia
Distribution: Debian Stable Testing Sid Slackware CentOS
Posts: 1,055
Blog Entries: 2

Rep: Reputation: 45
First of all does your router have dhcp?

It doesn't sound like it . go in and set a static IP address like 192.18.1.10

Try that
 
Old 03-31-2013, 09:56 PM   #8
M4trixSh4d0w
LQ Newbie
 
Registered: Mar 2013
Posts: 14

Original Poster
Rep: Reputation: Disabled
lspci -k
Code:
00:06.0 PCI bridge: Advanced Micro Devices [AMD] AMD-8111 PCI (rev 07)
00:07.0 ISA bridge: Advanced Micro Devices [AMD] AMD-8111 LPC (rev 05)
	Subsystem: Rioworks Device 3016
00:07.1 IDE interface: Advanced Micro Devices [AMD] AMD-8111 IDE (rev 03)
	Subsystem: Rioworks Device 3016
	Kernel driver in use: pata_amd
00:07.3 Bridge: Advanced Micro Devices [AMD] AMD-8111 ACPI (rev 05)
	Subsystem: Rioworks Device 3016
	Kernel driver in use: amd756_smbus
00:0a.0 PCI bridge: Advanced Micro Devices [AMD] AMD-8131 PCI-X Bridge (rev 12)
00:0a.1 PIC: Advanced Micro Devices [AMD] AMD-8131 PCI-X IOAPIC (rev 01)
	Subsystem: Advanced Micro Devices [AMD] AMD-8131 PCI-X IOAPIC
00:0b.0 PCI bridge: Advanced Micro Devices [AMD] AMD-8131 PCI-X Bridge (rev 12)
00:0b.1 PIC: Advanced Micro Devices [AMD] AMD-8131 PCI-X IOAPIC (rev 01)
	Subsystem: Advanced Micro Devices [AMD] AMD-8131 PCI-X IOAPIC
00:18.0 Host bridge: Advanced Micro Devices [AMD] K8 [Athlon64/Opteron] HyperTransport Technology Configuration
00:18.1 Host bridge: Advanced Micro Devices [AMD] K8 [Athlon64/Opteron] Address Map
00:18.2 Host bridge: Advanced Micro Devices [AMD] K8 [Athlon64/Opteron] DRAM Controller
00:18.3 Host bridge: Advanced Micro Devices [AMD] K8 [Athlon64/Opteron] Miscellaneous Control
	Kernel driver in use: k8temp
00:19.0 Host bridge: Advanced Micro Devices [AMD] K8 [Athlon64/Opteron] HyperTransport Technology Configuration
00:19.1 Host bridge: Advanced Micro Devices [AMD] K8 [Athlon64/Opteron] Address Map
00:19.2 Host bridge: Advanced Micro Devices [AMD] K8 [Athlon64/Opteron] DRAM Controller
00:19.3 Host bridge: Advanced Micro Devices [AMD] K8 [Athlon64/Opteron] Miscellaneous Control
	Kernel driver in use: k8temp
01:00.0 USB Controller: Advanced Micro Devices [AMD] AMD-8111 USB OHCI (rev 0b)
	Subsystem: Rioworks Device 3016
	Kernel driver in use: ohci_hcd
01:00.1 USB Controller: Advanced Micro Devices [AMD] AMD-8111 USB OHCI (rev 0b)
	Subsystem: Rioworks Device 3016
	Kernel driver in use: ohci_hcd
01:06.0 VGA compatible controller: ATI Technologies Inc Rage XL (rev 27)
	Subsystem: ATI Technologies Inc Rage XL
02:03.0 Ethernet controller: Broadcom Corporation NetXtreme BCM5702X Gigabit Ethernet (rev 02)
	Subsystem: Broadcom Corporation BCM5702 1000Base-T
	Kernel driver in use: tg3
02:04.0 Ethernet controller: Broadcom Corporation NetXtreme BCM5702X Gigabit Ethernet (rev 02)
	Subsystem: Broadcom Corporation BCM5702 1000Base-T
	Kernel driver in use: tg3
02:05.0 RAID bus controller: Silicon Image, Inc. SiI 3114 [SATALink/SATARaid] Serial ATA Controller (rev 02)
	Subsystem: Silicon Image, Inc. SiI 3114 SATARaid Controller
	Kernel driver in use: sata_sil
Thanks for the response.
 
Old 03-31-2013, 10:01 PM   #9
mreff555
Member
 
Registered: Sep 2011
Location: Philly
Distribution: Gentoo
Posts: 470

Rep: Reputation: Disabled
It's been a while since I had debian running but I would assume that some form of network manager should handle this. Assuming this is not an option, I curious, do you have two ethernet ports? Its also quite odd that your ethernet devices don't start at 0.

If nothing else is working see if you can set it up manually. try this.
Code:
sudo ifconfig eth1 up
sudo route add 192.168.1.1 eth1
sudo route add default gw 192.168.1.1 eth1
sudo dhcpcd eth1
Then try pinging your router. If that works, try pinging google.
If you can get to your router but not to google, it may be DNS
try this.

Code:
sudo echo 'nameserver 192.168.1.1' >> /etc/resolv.conf
Hope that helps

Last edited by mreff555; 03-31-2013 at 10:05 PM.
 
1 members found this post helpful.
Old 04-02-2013, 12:20 AM   #10
M4trixSh4d0w
LQ Newbie
 
Registered: Mar 2013
Posts: 14

Original Poster
Rep: Reputation: Disabled
I think that this is more along the lines of some hardware-software configuration. The computer I have Debian installed on (the hard drive) was actually installed from another computer and then the hard drive was transferred to the current computer. For some reason it wouldn't accept a boot disk or a flash drive, so I had to install Debian on the hard drive on another machine, which might have messed up some kind of configuration with the Ethernet ports. I actually have 2 machines with the same problem, the status of the Ethernet ports In The network manager device list says 'unknown' even if its plugged in.
So is there any way to reset the network configurations that were set up on install that were specific to the hardware on the machine installed on?
 
Old 04-02-2013, 01:39 AM   #11
lucky9
Member
 
Registered: May 2004
Location: Owasso, USA
Posts: 41

Rep: Reputation: 15
Not sure if it'll work but a sysctl at the command line will allow modification of kernel parameters.

It appears that you will need to use Eth1 as your network interface. Something else has grabbed hold of Eth0 so it's not usable. So do the lspci to get the correct information. Use that information to setup your network. You're almost there.
 
Old 04-02-2013, 01:55 AM   #12
evo2
LQ Guru
 
Registered: Jan 2009
Location: Japan
Distribution: Mostly Debian and Scientific Linux
Posts: 5,753

Rep: Reputation: 1288Reputation: 1288Reputation: 1288Reputation: 1288Reputation: 1288Reputation: 1288Reputation: 1288Reputation: 1288Reputation: 1288
Hi,
Quote:
Originally Posted by M4trixSh4d0w View Post
The computer I have Debian installed on (the hard drive) was actually installed from another computer and then the hard drive was transferred to the current computer.
This is explains why eth0 is missing. There will be a file (possibly 70-persistent-net.rules) in /etc/udev/rules.d that will have the mac address of the network device in the old machine set to eth0. If you comment out this line and restart udev (or perhaps just reboot), you should get an eth0. There will also probably be lines assigning eth1 and eth2 to the mac addresses in the new machine: modify as desired.

Quote:
So is there any way to reset the network configurations that were set up on install that were specific to the hardware on the machine installed on?
See above. To proceed further you'll need to tell us what you are using to manage your network devices. For example it could be one of:
1. network-manager
2. wicd
3. /etc/network/interfaces
Do you know which of these (if any) you are using?

Evo2.
 
Old 04-02-2013, 02:06 AM   #13
descendant_command
Senior Member
 
Registered: Mar 2012
Posts: 1,385

Rep: Reputation: 354Reputation: 354Reputation: 354Reputation: 354
Quote:
Originally Posted by M4trixSh4d0w View Post
The computer I have Debian installed on (the hard drive) was actually installed from another computer and then the hard drive was transferred to the current computer.
^^This.
eth0 is assigned to the nic on the previous box.
If you delete /etc/udev/rules.d/70-persistent-net.rules & reboot, it will recreate this file, getting rid of the old reference & listing your two interfaces as eth0 & eth1.

Your lspci shows both, and that they are using the tg3 kernel driver, so should "just work".

If they are listed in /etc/network/interfaces comment them out and they should become manageble with network-manager applet.
Or put in the correct stanza's to load them automatically at boot (either with static details or dhcp).
 
Old 04-04-2013, 09:09 PM   #14
M4trixSh4d0w
LQ Newbie
 
Registered: Mar 2013
Posts: 14

Original Poster
Rep: Reputation: Disabled
So I tried deleting the file, but it didn't get my internet to work, but It did re-create with a smaller file
here is the old one
Code:
# This file was automatically generated by the /lib/udev/write_net_rules
# program, run by the persistent-net-generator.rules rules file.
#
# You can modify it, as long as you keep each rule on a single
# line, and change only the value of the NAME= key.

# PCI device 0x14e4:0x167a (tg3)
SUBSYSTEM=="net", ACTION=="add", DRIVERS=="?*", ATTR{address}=="00:1a:a0:c7:e1:89", ATTR{dev_id}=="0x0", ATTR{type}=="1", KERNEL=="eth*", NAME="eth0"

# PCI device 0x168c:0x0013 (ath5k)
SUBSYSTEM=="net", ACTION=="add", DRIVERS=="?*", ATTR{address}=="00:0f:b5:28:bf:1e", ATTR{dev_id}=="0x0", ATTR{type}=="1", KERNEL=="wlan*", NAME="wlan0"

# PCI device 0x14e4:0x16a6 (tg3)
SUBSYSTEM=="net", ACTION=="add", DRIVERS=="?*", ATTR{address}=="00:50:45:5d:1a:f7", ATTR{dev_id}=="0x0", ATTR{type}=="1", KERNEL=="eth*", NAME="eth1"

# PCI device 0x14e4:0x16a6 (tg3)
SUBSYSTEM=="net", ACTION=="add", DRIVERS=="?*", ATTR{address}=="00:50:45:5d:1a:f6", ATTR{dev_id}=="0x0", ATTR{type}=="1", KERNEL=="eth*", NAME="eth2"
and the new one that was created
Code:
# This file was automatically generated by the /lib/udev/write_net_rules
# program, run by the persistent-net-generator.rules rules file.
#
# You can modify it, as long as you keep each rule on a single
# line, and change only the value of the NAME= key.

# PCI device 0x14e4:0x16a6 (tg3)
SUBSYSTEM=="net", ACTION=="add", DRIVERS=="?*", ATTR{address}=="00:50:45:5d:1a:f7", ATTR{dev_id}=="0x0", ATTR{type}=="1", KERNEL=="eth*", NAME="eth1"

# PCI device 0x14e4:0x16a6 (tg3)
SUBSYSTEM=="net", ACTION=="add", DRIVERS=="?*", ATTR{address}=="00:50:45:5d:1a:f6", ATTR{dev_id}=="0x0", ATTR{type}=="1", KERNEL=="eth*", NAME="eth0"
It still looks like it doesn't have the drivers (DRIVERS=="?*") so maybe thats the problem?
here is more info

And the new ifconfig -a
Code:
ifconfig -a
eth1      Link encap:Ethernet  HWaddr 00:50:45:5d:1a:f7  
          BROADCAST MULTICAST  MTU:1500  Metric:1
          RX packets:0 errors:0 dropped:0 overruns:0 frame:0
          TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000 
          RX bytes:0 (0.0 B)  TX bytes:0 (0.0 B)
          Interrupt:27 

eth2      Link encap:Ethernet  HWaddr 00:50:45:5d:1a:f6  
          BROADCAST MULTICAST  MTU:1500  Metric:1
          RX packets:0 errors:0 dropped:0 overruns:0 frame:0
          TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000 
          RX bytes:0 (0.0 B)  TX bytes:0 (0.0 B)
          Interrupt:27 

lo        Link encap:Local Loopback  
          inet addr:127.0.0.1  Mask:255.0.0.0
          inet6 addr: ::1/128 Scope:Host
          UP LOOPBACK RUNNING  MTU:16436  Metric:1
          RX packets:180 errors:0 dropped:0 overruns:0 frame:0
          TX packets:180 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:0 
          RX bytes:26753 (26.1 KiB)  TX bytes:26753 (26.1 KiB)
the new lspci -k
Code:
00:06.0 PCI bridge: Advanced Micro Devices [AMD] AMD-8111 PCI (rev 07)
00:07.0 ISA bridge: Advanced Micro Devices [AMD] AMD-8111 LPC (rev 05)
	Subsystem: Rioworks Device 3016
00:07.1 IDE interface: Advanced Micro Devices [AMD] AMD-8111 IDE (rev 03)
	Subsystem: Rioworks Device 3016
	Kernel driver in use: pata_amd
00:07.3 Bridge: Advanced Micro Devices [AMD] AMD-8111 ACPI (rev 05)
	Subsystem: Rioworks Device 3016
	Kernel driver in use: amd756_smbus
00:0a.0 PCI bridge: Advanced Micro Devices [AMD] AMD-8131 PCI-X Bridge (rev 12)
00:0a.1 PIC: Advanced Micro Devices [AMD] AMD-8131 PCI-X IOAPIC (rev 01)
	Subsystem: Advanced Micro Devices [AMD] AMD-8131 PCI-X IOAPIC
00:0b.0 PCI bridge: Advanced Micro Devices [AMD] AMD-8131 PCI-X Bridge (rev 12)
00:0b.1 PIC: Advanced Micro Devices [AMD] AMD-8131 PCI-X IOAPIC (rev 01)
	Subsystem: Advanced Micro Devices [AMD] AMD-8131 PCI-X IOAPIC
00:18.0 Host bridge: Advanced Micro Devices [AMD] K8 [Athlon64/Opteron] HyperTransport Technology Configuration
00:18.1 Host bridge: Advanced Micro Devices [AMD] K8 [Athlon64/Opteron] Address Map
00:18.2 Host bridge: Advanced Micro Devices [AMD] K8 [Athlon64/Opteron] DRAM Controller
00:18.3 Host bridge: Advanced Micro Devices [AMD] K8 [Athlon64/Opteron] Miscellaneous Control
	Kernel driver in use: k8temp
00:19.0 Host bridge: Advanced Micro Devices [AMD] K8 [Athlon64/Opteron] HyperTransport Technology Configuration
00:19.1 Host bridge: Advanced Micro Devices [AMD] K8 [Athlon64/Opteron] Address Map
00:19.2 Host bridge: Advanced Micro Devices [AMD] K8 [Athlon64/Opteron] DRAM Controller
00:19.3 Host bridge: Advanced Micro Devices [AMD] K8 [Athlon64/Opteron] Miscellaneous Control
	Kernel driver in use: k8temp
01:00.0 USB Controller: Advanced Micro Devices [AMD] AMD-8111 USB OHCI (rev 0b)
	Subsystem: Rioworks Device 3016
	Kernel driver in use: ohci_hcd
01:00.1 USB Controller: Advanced Micro Devices [AMD] AMD-8111 USB OHCI (rev 0b)
	Subsystem: Rioworks Device 3016
	Kernel driver in use: ohci_hcd
01:06.0 VGA compatible controller: ATI Technologies Inc Rage XL (rev 27)
	Subsystem: ATI Technologies Inc Rage XL
02:03.0 Ethernet controller: Broadcom Corporation NetXtreme BCM5702X Gigabit Ethernet (rev 02)
	Subsystem: Broadcom Corporation BCM5702 1000Base-T
	Kernel driver in use: tg3
02:04.0 Ethernet controller: Broadcom Corporation NetXtreme BCM5702X Gigabit Ethernet (rev 02)
	Subsystem: Broadcom Corporation BCM5702 1000Base-T
	Kernel driver in use: tg3
02:05.0 RAID bus controller: Silicon Image, Inc. SiI 3114 [SATALink/SATARaid] Serial ATA Controller (rev 02)
	Subsystem: Silicon Image, Inc. SiI 3114 SATARaid Controller
	Kernel driver in use: sata_sil
 
Old 04-04-2013, 09:11 PM   #15
M4trixSh4d0w
LQ Newbie
 
Registered: Mar 2013
Posts: 14

Original Poster
Rep: Reputation: Disabled
It didn't fix the eth0 either

Quote:
Originally Posted by evo2 View Post
1. network-manager
2. wicd
3. /etc/network/interfaces
Do you know which of these (if any) you are using?

Evo2.
I don't believe I am using any of them. I didn't set anything in particular up.
 
  


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



Similar Threads
Thread Thread Starter Forum Replies Last Post
linux box ethernet not detecting connection to router agatone Linux - Networking 5 12-25-2012 01:31 PM
Inconsistant wired ethernet connection only with Debian Squeeze Elixer Debian 3 01-10-2012 10:58 PM
Debian Lenny AMD64 netinstall not detecting ethernet correctly the trooper Debian 6 07-28-2008 02:13 PM
debian not detecting wireless ethernet card macmanus_bros Linux - Hardware 2 06-27-2005 10:51 PM


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

Main Menu
Advertisement
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
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration