1

I don't know what's happening here, but I can't connect to internet using Ethernet/LAN.

When I run lshw -C net I got this result:

root@ubntnginx:/etc/netplan# lshw -C net
  *-network DISABLED        
       description: Ethernet interface
       product: RTL810xE PCI Express Fast Ethernet controller
       vendor: Realtek Semiconductor Co., Ltd.
       physical id: 0
       bus info: pci@0000:02:00.0
       logical name: ens33
       version: 02
       serial: 18:a9:05:1a:b7:c1
       width: 64 bits
       clock: 33MHz
       capabilities: pm msi pciexpress msix vpd bus_master cap_list rom ethernet physical
       configuration: broadcast=yes driver=r8169 latency=0 link=no multicast=yes
       resources: irq:17 ioport:e800(size=256) memory:feaff000-feafffff memory:fdff0000-fdffffff memory:feac0000-feadffff

And this is result from ifconfig command:

lo: flags=73<UP,LOOPBACK,RUNNING>  mtu 65536
        inet 127.0.0.1  netmask 255.0.0.0
        inet6 ::1  prefixlen 128  scopeid 0x10<host>
        loop  txqueuelen 1000  (Local Loopback)
        RX packets 9840  bytes 721798 (721.7 KB)
        RX errors 0  dropped 0  overruns 0  frame 0
        TX packets 9840  bytes 721798 (721.7 KB)
        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0

This is the result from cat /etc/netplan

cat /etc/netplan/00-installer-config.yaml
# This is the network config written by 'subiquity'
network:
  ethernets:
    ens2:
      dhcp4: true
  version: 2

And this is from ip addr

1: lo: <LOOPBACK,UP,LOWER_UP> mtu 65536 qdisc noqueue state UNKNOWN group default qlen 1000
    link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
    inet 127.0.0.1/8 scope host lo
       valid_lft forever preferred_lft forever
    inet6 ::1/128 scope host 
       valid_lft forever preferred_lft forever
2: ens33: <BROADCAST,MULTICAST> mtu 1500 qdisc noop state DOWN group default qlen 1000
    link/ether 18:a9:05:1a:b7:c1 brd ff:ff:ff:ff:ff:ff

When I check the network-manager status using sudo service network-manager status I got warning that the files in etc/network/interfaces is not found. And unlike this answer: here, I dont have files in /var/lib/NetworkManager/NetworkManager.state

Any Idea how to fix this?

Catto
  • 113

1 Answers1

5

It appears your active network adapter is named ens33 - your netplan config should be adjusted to accommodate this:

# This is the network config written by 'subiquity'
network:
  ethernets:
    ens33:
      dhcp4: true
  version: 2

Now run sudo netplan apply. This should hopefully give your interface ens33 an IP address from the DHCP server.

Artur Meinild
  • 31,035