I just resolved an issue when bringing up an interface, but I'm at a loss to explain why it worked. So I'm looking for someone with more knowledge of the linux networking stack to explain this to me.

This machine has two Broadcom gigabit nics, using the tg3 driver. OS is CentOS 5.7. These nics are onboard.

One was already configured and working. I attached a cable into the second one, with the other end in a gigabit switch.

ethtool eth0 (the one that worked) showed a link, full duplex, auto negotiated, gigabit speed. So no change there.

ethtool eth1, however, showed no link. The link lights were on, although the link lights on the switch showed that it wasn't negotiating correctly. So, I figured that it was some sort of autonegotiation issue, and used ethtool -s eth1 autoneg off speed 100 duplex full to try to get a link. This failed - ethtool reporting "cannot set new settings invalid argument".

After much mucking about and hard thinking, I was at a loss, and I finally got around to checking the ifcfg-eth1 file. This had DHCP set to on, although it was set to ONBOOT=no. There is no DHCP server on this net.

Also, I'll add that I tried, during this process, bringing the card up and down several times, and when I made the following changes, the card was down.

I removed the BOOTPROTO=dhcp line, and set ONBOOT to yes, as well as giving it a valid IP and the other usual settings. ifup eth1 and amazingly, link was achieved.

What I'm confused about is that I would have thought that ethtool would be able to manage a card, and detect a link, without any reference to the os network settings for that device. In past experience, even if an ethernet card isn't configured, or "up", ethtool will show a link when there is a physical link to the card.

But, obviously, at least in this case, my assumptions are incorrect.

Does anyone have an explanation as to why this behavior exhibited itself?


1 Answer 1


Not 100% certain, but I believe the interface doesn't have to be configured, but it does have to be up. Did you try a simple ifconfig eth1 up or ip link set eth1 up?

  • I suspect you're right. I frankly don't know if the interface was up or not. Still, I would have suspected "link detected" to show regardless of the state of interface as far as the OS was concerned.
    – malcolmpdx
    Feb 4, 2012 at 0:01
  • This is correct. The interface must be up for ethtool to work (and for ethtool to detect link status). Bringing the interface up actually tells the driver to bring the card online, its more than just an os-level change, its hardware as well.
    – phemmer
    Feb 5, 2012 at 5:24

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .