2

I'm using Ubuntu 18.04.

I have exactly the same issue as described in this question on Unix & Linux; my laptop's ethernet/wired cannot receive DHCP offer.

  1. I can verify it's not a network/server issue, as it works in live cd. Other laptop works fine using the same cable, so definitely not an issue with a cable.
  2. My laptop ethernet doesn't work at my home nor my friend's place.
  3. I tried the rfc and identifier workarounds mentioned by this Ubuntu Forums thread, but to no avail.
  4. I tried disabling ufw/gufw firewall, no avail.
  5. dhclient <iface_name> simply times out. When a static IP is used, NetworkManager shows it's connected, but I can't ping anywhere.
  6. I tried clearing /etc/NetworkManager/system-connections/, to no avail.
  7. I tried r8168-dkms driver, to no avail.
  8. I tried all options of link negotiation, to no avail.
  9. I'm using kernel 4.15.0-29.31, I tried booting older kernel 4.15.0-23.25, no avail. Cold boot (without restart) 4.15.0-23.25 or 4.15.0-20 through GRUB advanced options resolve my issue.
  10. No issue on wifi.

This is the second time this has happened to me. Previously I simply gave up and reformated/reinstalled. Ethernet was previously functional again from fresh install until now (2 months later).

I'm trying to avoid doing a fresh install this time as this probably will happen again if the (currently unknown) cause is not addressed.

NetworkManager log:

device (enp3s0f1): carrier: link connected
device (enp3s0f1): state change: unavailable -> disconnected (reason 'carrier-changed', sys-iface-state: 'managed')
manager: startup complete
device (enp3s0f1): Activation: starting connection 'Wired connection 1' ()
audit: op="connection-activate" uuid="" name="Wired connection 1" pid= uid= result="success"
device (enp3s0f1): state change: disconnected -> prepare (reason 'none', sys-iface-state: 'managed')
manager: NetworkManager state is now CONNECTING
device (enp3s0f1): state change: prepare -> config (reason 'none', sys-iface-state: 'managed')
device (enp3s0f1): state change: config -> ip-config (reason 'none', sys-iface-state: 'managed')
dhcp4 (enp3s0f1): activation: beginning transaction (timeout in 45 seconds)
dhcp4 (enp3s0f1): dhclient started with pid 
device (enp3s0f1): carrier: link connected
dhcp4 (enp3s0f1): request timed out
dhcp4 (enp3s0f1): state changed unknown -> timeout
dhcp4 (enp3s0f1): canceled DHCP transaction, DHCP client pid 
dhcp4 (enp3s0f1): state changed timeout -> done
device (enp3s0f1): state change: ip-config -> failed (reason 'ip-config-unavailable', sys-iface-state: 'managed')
manager: NetworkManager state is now DISCONNECTED
device (enp3s0f1): Activation: failed for connection 'Wired connection 1'
device (enp3s0f1): state change: failed -> disconnected (reason 'none', sys-iface-state: 'managed')
device (enp3s0f1): state change: disconnected -> unavailable (reason 'carrier-changed', sys-iface-state: 'managed')
device (enp3s0f1): carrier: link connected
device (enp3s0f1): state change: unavailable -> disconnected (reason 'carrier-changed', sys-iface-state: 'managed')

dhclient log:

dhcp-init: Using DHCP client 'dhclient'
dhcp4 (enp3s0f1): dhclient started with pid 
DHCPDISCOVER on enp3s0f1 to 255.255.255.255 port 67 interval 3 (xid=0x48f58660)
DHCPDISCOVER on enp3s0f1 to 255.255.255.255 port 67 interval 5 (xid=0x48f58660)
DHCPDISCOVER on enp3s0f1 to 255.255.255.255 port 67 interval 13 (xid=0x48f58660)
DHCPDISCOVER on enp3s0f1 to 255.255.255.255 port 67 interval 7 (xid=0x48f58660)
DHCPDISCOVER on enp3s0f1 to 255.255.255.255 port 67 interval 8 (xid=0x48f58660)
DHCPDISCOVER on enp3s0f1 to 255.255.255.255 port 67 interval 9 (xid=0x48f58660)
$ lspci | grep Ethernet
03:00.1 Ethernet controller: Realtek Semiconductor Co., Ltd. RTL8111/8168/8411 PCI Express Gigabit Ethernet Controller (rev 12)
$ cat /etc/network/interfaces
# interfaces(5) file used by ifup(8) and ifdown(8)
auto lo
iface lo inet loopback
$ sudo lshw -C network
  *-network                 
       description: Wireless interface
       product: Wireless 7260
       vendor: Intel Corporation
       physical id: 0
       bus info: pci@0000:02:00.0
       logical name: wlp2s0
       version: 73
       serial: 
       width: 64 bits
       clock: 33MHz
       capabilities: pm msi pciexpress bus_master cap_list ethernet physical wireless
       configuration: broadcast=yes driver=iwlwifi driverversion=4.15.0-29-generic firmware=17.948900127.0 ip=10.233.9.0 latency=0 link=yes multicast=yes wireless=IEEE 802.11
       resources: irq:47 memory:e3500000-e3501fff
  *-network
       description: Ethernet interface
       product: RTL8111/8168/8411 PCI Express Gigabit Ethernet Controller
       vendor: Realtek Semiconductor Co., Ltd.
       physical id: 0.1
       bus info: pci@0000:03:00.1
       logical name: enp3s0f1
       version: 12
       serial: 
       size: 1Gbit/s
       capacity: 1Gbit/s
       width: 64 bits
       clock: 33MHz
       capabilities: pm msi pciexpress msix vpd bus_master cap_list ethernet physical tp mii 10bt 10bt-fd 100bt 100bt-fd 1000bt 1000bt-fd autonegotiation
       configuration: autonegotiation=on broadcast=yes driver=r8169 driverversion=2.3LK-NAPI duplex=full firmware=rtl8411-2_0.0.1 07/08/13 latency=0 link=yes multicast=yes port=MII speed=1Gbit/s
       resources: irq:19 ioport:4000(size=256) memory:e3404000-e3404fff memory:e3400000-e3403fff
$ cat /etc/NetworkManager/NetworkManager.conf
[main]
plugins=ifupdown,keyfile

[ifupdown]
managed=false

Edit: Looks similar to Unable to activate the ethernet connection after upgrading to Ubuntu 18.04. User resolved it with recent update. But in this case, recent update could have broken it instead.

Edit2: /etc/udev/rules.d/70-persistent-net.rules is missing, but wifi works.

Edit3: Just tried a USB ethernet (Dell Docking D3100), it works. So, this is an issue of my laptop realtek built-in nic.

1
  • I have the same problem. I suspect that the network interface is silently dropping some packets. Evidence: In my case, I ran tcpdump on the client, which makes the network interface promiscuous, using sudo tcpdump -n udp port 68 -vv, and the connection succeeds when I connect the ethernet cable to the network. Contrast with sudo tcpdump -n udp port 68 --no-promiscuous-mode -vv where the connection does not succeed.
    – Flux
    Jan 30, 2019 at 17:13

1 Answer 1

2

My latest kernel installed is 4.15.0-29. Cold booting older kernel 4.15.0-23 or 4.15.0-20 resolved my issue.

Similar kernel issues reported:

How do I submit a kernel bug report? Which logs should I attach?

Edit: Submitted a bug report #1784542.

Edit2: canonical-livepatch has to be disabled after booting older kernel to avoid issue with compiz.

Edit3: Maybe related to Spectre mitigation (see this article).

Edit4: There is a working fix to be backported.

Edit5: Fix released in kernel 4.15.0-33.36. This issue came back when I first enabled canonical-livepatch, but a reboot resolved it.

1
  • 1
    Run ubuntu-bug linux that will create a bug report.
    – Pilot6
    Jul 30, 2018 at 10:35

You must log in to answer this question.

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