LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   Loses network connectivity on boot... (https://www.linuxquestions.org/questions/linux-newbie-8/loses-network-connectivity-on-boot-746467/)

drydo 08-10-2009 10:12 AM

Loses network connectivity on boot...
 
Hi

I'm running a deiban live-cd (with persistance) running on Lenny but for some reason my LAN connection isn't working correctly. When the machine first boots up it flashes up with...

Quote:

hotlink (?) : renamed network interface eth0 to eth1
...which I'm guessing is just reassigning that device ID - although from my searching 'ETH0' should be the default port / device assignment. If I perform a 'ifconfig' I get the following...

Quote:

lo Link encap:Local Loopback
inet addr:127.0.0.1 Mask:255.0.0.0
UP LOOPBACK RUNNING MTU:16436 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:0
RX bytes:0 (0.0 B) TX bytes:0 (0.0 B)
...with a dmesg | grep eth I get the following...

Quote:

[ 3.600418] eth0: RealTek RTL8139 at 0xf200, 00:21:97:97:08:6f, IRQ 17
[ 3.600476] eth0: Identified 8139 chip type 'RTL-8100B/8139D'
[ 11.243499] Driver 'sd' needs updating - please use bus_type methods
[ 49.305698] udev: renamed network interface eth0 to eth1
...and if I run 'mii-tool eth0' I get...

Quote:

SIOCGMIIPHY on 'eth0' failed: No such device
and 'mii-tool eth1' gives...

Quote:

SIOCGMIIPHY on 'eth1' failed: Invalid argument
But if I run 'dhclient eth1' - it either a) refreshes or b) invokes DCHP assigns itself a IP address and works fine.

Of course, what I want is for the device to bootup in a ready and working mode rather than jumping through hoops. From the looks of things it is reassigning itself from eth0 to eth1 (why though?) and not properly configuring the itself or firing DHCP? I've tried setting a static address but that didn't do anything and to be quite frank I'm a linux newbie in all this and feeling lost again.

Can anyone point me in the right direction?

M

malekmustaq 08-10-2009 11:12 AM

drydo:

Have you ascertained the system uses the right nic card driver?

drydo 08-10-2009 11:18 AM

AFAIK, it reports the matching driver and its the correct one. Plus I'm guessing that when the 'dhclient eth1' is executed if I had the wrong driver it would choke on that? + There's only one on-board NIC.

makuyl 08-10-2009 11:47 AM

You can use an udev rule to make it stick to eth0 http://www.debianhelp.co.uk/udev.htm

malekmustaq 08-10-2009 12:47 PM

drydo,

try again: --#: ifconfig -a
If eth0 or eth1 are not present, like the which you have posted above, there is big chance that the card is not mounted properly in the system.

to counter check:
try examine --#: cat /proc/net/route [find out which is what]
also try ----#: cat /proc/net/arp [which is using what number]

the obstacle maybe lies in the fact that your system is run from CD there is no way we can employ a final fix that guarantees to run the next boot. Unless maybe if you will finally install this debian into the hard drive. You will need extra hop each time you wanted to go online through the NIC, except when your new configuration is burned into another cd wherein you availed the udev rule solution into the new cd.

HOnestly I gave time to ponder over the problem, but since I am not a guru my capability to help you is only limited to that.

Overall, if the NIC driver is good (is it normal to report IRQ 17 in Linux?), and the hardware connection is healthy, then it is the CD, not your machine.

hope this helps.

good luck.

may a guru come to help you.
ameyn.

drydo 08-11-2009 04:52 AM

Well I managed to crack and you both put me on the right path. Here's how I sorted it...

I pretty much agreed with malekmustaq that the device wasn't being mounted correctly and was being a pest but I was fumbling about until I read the link that makuyl posted. I had a nose into the /etc/udev/rules.d directory and found that the file '70-persistent-net.rules' files was referencing four different MAC addresses and assigning the real mac address to eth1. I commented out the other 3 lines referencing the other mac address and reset the line to eth0. Rebooted and hey presto I've got internet connectivity!

+ I'm running live-cd from a usb key so the change was proven straight away.

Thank you both for pointing me in the right direction...

malekmustaq 08-11-2009 06:01 AM

drydo,

Congratulations! you got it right.

Q--"+ I'm running live-cd from a usb key so the change was proven straight away."

Reply: Ow! yea I didn't notice its a USB I thought twas a CD. Right on of course. Good Luck!


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