LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Networking (https://www.linuxquestions.org/questions/linux-networking-3/)
-   -   Ethernet auto-connect, auto-sense doesn't work (https://www.linuxquestions.org/questions/linux-networking-3/ethernet-auto-connect-auto-sense-doesnt-work-860604/)

mikevandeberg 02-03-2011 10:32 PM

Ethernet auto-connect, auto-sense doesn't work
 
I have noticed that a common issue to several distros is the fact that the networking subsystem doesn't automatically detect the link if an ethernet connection is disconnected and then re-connected to the NIC after boot. If the ethernet cable is connected after the system is up and running, nothing happens - ethtool eth0 shows link detected: no, and you have to restart the network service to let the NIC know that there is in fact a link, and actually connect.

I have a Fedora14 (KDE) box with a brand new Asus motherboard with embedded NIC. Everything works great except the auto-detect of a freshly connected ethernet connection if the link is down to begin with.

Am I missing a ethernet link sentinel utility or something, or is this just the way linux works?

I have done plenty of research on plenty of posts, and it seems this is a common problem, with no solution other than manually or programatically restarting the network service in a script to detect the link after a disconnect.

Thanks in advance for any ideas/solutions.

Mike

xeleema 02-04-2011 01:16 AM

Greetingz!

Quote:

Originally Posted by mikevandeberg (Post 4247833)
I have noticed that a common issue to several distros is the fact that the networking subsystem doesn't automatically detect the link if an ethernet connection is disconnected and then re-connected to the NIC after boot.

That depends on your definition of "detect". Ubuntu will actually notify you on your desktop that you've lost the link. Others report to syslog. At the very least, the card knows the link is dead and reports to the drive.

Quote:

Originally Posted by mikevandeberg (Post 4247833)
If the ethernet cable is connected after the system is up and running, nothing happens - ethtool eth0 shows link detected: no, and you have to restart the network service to let the NIC know that there is in fact a link, and actually connect.

That may be true for DHCP clients, however an "ifconfig eth# down" and "ifconfig eth# up" might fix it in most cases. I've seen several opensource projects dedicated to "do stuff when the NIC loses it's connection, do more stuff when the connection comes back", but I can't think of any off the top of my head (I only use DHCP for my WiFi now a days).

Quote:

Originally Posted by mikevandeberg (Post 4247833)
Am I missing a ethernet link sentinel utility or something, or is this just the way linux works?

Yes, there are things that can watch & configure NICs based on link activity...

Quote:

Originally Posted by mikevandeberg (Post 4247833)
I have done plenty of research on plenty of posts, and it seems this is a common problem, with no solution other than manually or programatically restarting the network service in a script to detect the link after a disconnect.

Something like ifplugd, perhaps?
I would imagine the reason this isn't implemented across-the-board on most distros is because of this;
When you "ifconfig eth# down", what stops the daemon from upping the NIC again?

mikevandeberg 02-11-2011 08:08 AM

Thanks xeleema,

I don't really know what happened, but for some reason, without changing anything in the config, the NIC started negotiating to 1 gig with my router, and began auto-connecting when the cable was disconnected and re-connected again!! Weird! I swear I didn't change a thing....

Gotta love the Linux quirks sometimes...

xeleema 02-11-2011 10:26 AM

Kewl!
Can you mark this as [SOLVED] via "Thread Tools" (up at the top of the page). Maybe hit "Yes" next to any posts that might have been helpful? :)


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