[Solved] After dist-upgrade to Debian Jessie, Intel eth0 doesn’t come up on boot
Upon reboot after upgrading yet another Debian host to sweet Jessie, I was dismayed to lose connectivity – a slight annoyance when administering through the Internet. Later, with screen & keyboard attached to the server, I found that the Intel Ethernet interface using the e1000e module had not come up on boot… A simple ‘ip link set eth0 up’ fixed that… Until the next reboot.
/etc/network/interfaces was still the same as before upgrade, complete with the necessary ‘auto eth0’ line present before the ‘iface eth0 inet static’ line. And everything was fine once the interface had been set up manually.
Looking at dmesg yielded an unusual “[ 1.818847] e1000e 0000:00:19.0 eth0: Unsupported MTU setting” – strange, considering I had been using a 9000 bits MTU without issue before… That error message let me to the cause of my problem: the driver maintainer chose that from kernel 3.15 onwards, calculation of the Ethernet frame’s length always takes into account the VLAN header, even when none is present… And I was running Linux 3.16:
diff --git a/drivers/net/ethernet/intel/e1000e/netdev.c b/drivers/net/ethernet/intel/e1000e/netdev.c index d50c91e..165f7bc 100644 --- a/drivers/net/ethernet/intel/e1000e/netdev.c +++ b/drivers/net/ethernet/intel/e1000e/netdev.c @@ -5687,7 +5687,7 @@ struct rtnl_link_stats64 *e1000e_get_stats64(struct net_device *netdev, static int e1000_change_mtu(struct net_device *netdev, int new_mtu) { struct e1000_adapter *adapter = netdev_priv(netdev); - int max_frame = new_mtu + ETH_HLEN + ETH_FCS_LEN; + int max_frame = new_mtu + VLAN_HLEN + ETH_HLEN + ETH_FCS_LEN; /* Jumbo frame support */ if ((max_frame > ETH_FRAME_LEN + ETH_FCS_LEN) &&
As the author remarked: “The hardware has a set limit on supported maximum frame size (9018), and with the addition of the VLAN_HLEN (4) in calculating the header size (now it is 22) , the max configurable MTU is now 8996”.
So there…
diff --git a/network/interfaces b/network/interfaces index ee4e27d..a094569 100644 --- a/network/interfaces +++ b/network/interfaces @@ -7,7 +7,7 @@ iface lo inet loopback auto eth0 iface eth0 inet static - mtu 9000 + mtu 8996 address 10.128.0.2 network 10.128.0.0 netmask 255.255.255.0
And a reboot later the host is still connected – problem solved. Now to avoid fragmentation I’ll have to set a few other hosts’ MTU to 8996 too… Damn.
0 responses to “[Solved] After dist-upgrade to Debian Jessie, Intel eth0 doesn’t come up on boot”
Leave a Reply
You must be logged in to post a comment.
[Solved] After dist-upgrade to #Debian #Jessie, #Intel eth0 #Ethernet doesn’t come up on boot
http://t.co/5v9qEf7LX5
Thanks! I found your description by searching for Debian and eth0, as my internet connection was lost after an aptitude full-upgrade. The information here helped me. I changed part of the content of my /etc/network/interfaces file from
# The primary network interface
allow-hotplug eth0
iface eth0 inet dhcp
# The primary network interface
# allow-hotplug eth0
auto eth0
iface eth0 inet dhcp
which made the trick.
Thanks!
This is actually a bug – they should not have limited that (obviously) and the corrected patch is at: http://www.spinics.net/lists/netdev/msg324439.html
Thanks for mentioning that – I wasn’t aware. Looks like Linux 4.1.4 contains the “e1000e: Cleanup handling of VLAN_HLEN as a part of max frame size” patch by Alexander Duyck: http://lwn.net/Articles/653401/