0

I've just completed a fresh install of Ubuntu Server 18.04 on dedicated hardware. After login, the bonded network interface is not assigned an IP from DHCP. If I run sudo dhclient the bonded interface gets an IP and everything appears to work. After a reboot, I'm back to a non-working network.

If I execute sudo ip address show I can see that my interface is down. After sudo ip link bond0 up the interface comes up without an IP.

I've looked at this question already: Ubuntu 18.04 ethernet not configuring automatically That question does not address my problem. The question includes ifup which is not available on my system. The accepted answer includes /etc/network/interfaces which is not available on 18.04.

I've looked at this question: Ubuntu Server 18.04 waiting for Network at startup although the network is ok which specifically calls out wireless, which is not my situation and also does not have an accepted answer.

There's this question: Ubuntu server 18.04 - No IP address with Netplan This is a zero reputation question with no answer. There's one comment that recommends capturing packets and submitting a bug report. I've run a packet capture with tcpdump on DHCP traffic and the only data I get is 10 packets dropped by interface (I assume this was not DCHP traffic).

I did not find any other existing questions that seemed related.

So my question is twofold:

  1. Is this a bug?
  2. Am I expected to manually set up a networking interface after installation?

Edit: Additional Information

lshw:

  *-network:0
       description: Ethernet interface
       product: 82576 Gigabit Network Connection
       vendor: Intel Corporation
       physical id: 0
       bus info: pci@0000:05:00.0
       logical name: enp5s0f0
       version: 01
       serial: 3e:e4:cf:e3:41:b2
       size: 1Gbit/s
       capacity: 1Gbit/s
       width: 32 bits
       clock: 33MHz
       capabilities: pm msi msix pciexpress bus_master cap_list rom ethernet physical tp 10bt 10bt-fd 100bt 100bt-fd 1000bt-fd autonegotiation
       configuration: autonegotiation=on broadcast=yes driver=igb driverversion=5.4.0-k duplex=full firmware=1.2.3 latency=0 link=yes multicast=yes port=twisted pair slave=yes speed=1Gbit/s
       resources: irq:25 memory:c0000000-c001ffff memory:c0020000-c003ffff ioport:ef80(size=32) memory:c00c0000-c00c3fff memory:c0040000-c005ffff memory:c00c4000-c00e3fff memory:c00e4000-c0103fff
  *-network:1
       description: Ethernet interface
       product: 82576 Gigabit Network Connection
       vendor: Intel Corporation
       physical id: 0.1
       bus info: pci@0000:05:00.1
       logical name: enp5s0f1
       version: 01
       serial: 3e:e4:cf:e3:41:b2
       size: 1Gbit/s
       capacity: 1Gbit/s
       width: 32 bits
       clock: 33MHz
       capabilities: pm msi msix pciexpress bus_master cap_list rom ethernet physical tp 10bt 10bt-fd 100bt 100bt-fd 1000bt-fd autonegotiation
       configuration: autonegotiation=on broadcast=yes driver=igb driverversion=5.4.0-k duplex=full firmware=1.2.3 latency=0 link=yes multicast=yes port=twisted pair slave=yes speed=1Gbit/s
       resources: irq:35 memory:c0060000-c007ffff memory:c0080000-c009ffff ioport:ef40(size=32) memory:c0104000-c0107fff memory:c00a0000-c00bffff memory:c0108000-c0127fff memory:c0128000-c0147fff
  *-network DISABLED
       description: Ethernet interface
       physical id: 1
       logical name: bond0
       serial: 3e:e4:cf:e3:41:b2
       size: 1Gbit/s
       capabilities: ethernet physical
       configuration: autonegotiation=off broadcast=yes driver=bonding driverversion=3.7.1 duplex=full firmware=2 link=no master=yes multicast=yes speed=1Gbit/s

/etc/netplan/*.yaml:

# This file is generated from information provided by
# the datasource.  Changes to it will not persist across an instance.
# To disable cloud-init's network configuration capabilities, write a file
# /etc/cloud/cloud.cfg.d/99-disable-network-config.cfg with the following:
# network: {config: disabled}
network:
    bonds:
        bond0:
            addresses: []
            interfaces:
            - enp5s0f0
            - enp5s0f1
            parameters:
                mode: active-backup
    ethernets:
        enp5s0f0:
            addresses: []
            dhcp4: false
            dhcp6: false
        enp5s0f1:
            addresses: []
            dhcp4: false
            dhcp6: false
    version: 2
htaccess
  • 1,528
c3maw
  • 3

1 Answers1

0

My understanding is that on Ubuntu Server, you must configure netplan manually, to match your actual physical and DHCP/address network environment.

Try this...

Note: keep the indentation at 2 spaces.

Note: dhcp4: true can be changed to addresses: [10.1.1.100/24] and gateway4: 10.1.1.1 if a fixed IP is required. (Example addresses only).

network:
  version: 2
  renderer: networkd
    bonds:
      bond0:
        addresses: []
        dhcp4: true
        interfaces:
          - enp5s0f0
          - enp5s0f1
        parameters:
          mode: active-backup
    ethernets:
      enp5s0f0:
        addresses: []
        dhcp4: false
        dhcp6: false
      enp5s0f1:
        addresses: []
        dhcp4: false
        dhcp6: false

In terminal...

sudo netplan -debug generate # generate config files

sudo netplan apply # apply new configuration

reboot # reboot system and confirm network operation

postnote: see here for more netplan examples, or here for netplan references.

heynnema
  • 73,649