0

I am trying to install ubuntu server 18.04 inside proxmox. At the network configuration page, ubuntu complains that autoconfiguration failed and gives me the choice to continue without networking. The installation, however, completed smoothly, despite the fact that no networking is present... I still have no internet access after the installation finished, so I went on to configure a static ip. Here is my netplan yaml configuration:

network:
    version: 2
    renderer: networkd
    ethernets:
        ens18:
            dhcp4: no
            addresses: [10.0.1.101/24, ]
            gateway4: 10.0.1.1
            nameservers:
                addresses: [8.8.8.8, 8.8.4.4]

ip route on the vm gives:

default via 10.0.1.1 dev ens18 proto static
10.0.1.0/24 dev ens18 proto kernel scope link src 10.0.1.101

ip route on the host gives:

default via 10.0.1.1 dev vmbr0 onlink
10.0.1.0/24 dev vmbr0 proto kernel scope link src 10.0.1.100
10.0.1.0/24 dev vmbr1 proto kernel scope link src 10.0.1.101

/etc/network/interfaces on the host contains:

auto lo
iface lo inet loopback

iface eno1 inet manual

iface eno2 inet manual

iface eno3 inet manual

iface eno4 inet manual

auto vmbr0
iface vmbr0 inet static
        address  10.0.1.100
        netmask  255.255.255.0
        gateway  10.0.1.1
        bridge-ports eno1
        bridge-stp off
        bridge-fd 0

auto vmbr1
iface vmbr1 inet static
        address  10.0.1.101
        netmask  24
        bridge-ports eno2
        bridge-stp off
        bridge-fd 0

Pinging anything, including 10.0.1.1 the gateway, gives destination host unreachable. SSH gives no route to host

  • This is valid yaml and the routing table is valid, so there aren't any problems with syntax that we can help you with. We don't know that the configuration is correct without knowing what the network configuration is on the host. Did you specifically try pinging your gateway (10.0.1.1) to confirm whether it's reachable? – slangasek Sep 1 at 20:44
  • Thanks for responding! I have updated my post to contain the network configs on the host. Pinging 10.0.1.1 from the vm yields destination host unreachable. – Luke Kong Sep 2 at 2:38
  • Which bridge is proxmox connected to? I can give you a more specific answer if I know this also. – slangasek Sep 3 at 5:35
  • The node is connected to vmbr0. – Luke Kong Sep 3 at 22:54
0

You are using the same IP address on both the host and the guest, which is incorrect. When running a VM, you must either used routed networking, in which case your gateway in the guest is an IP address configured on the bridge on the host; or you use bridged networking, in which case the guest's gateway is some address reachable on the bridge which may or may not be on the host.

  • Do you mean the vm and the node can't share the same gateway? I just changed the vm's gateway to 10.0.1.100 (the node's ip), but it still didn't work... – Luke Kong Sep 3 at 22:55
  • I'm not talking about the gateway, I am talking about the IP address. Your configs show that the host is using IP 10.0.1.101 on vmbr1, and the guest is using it on ens18, and this is likely causing problems. – slangasek Sep 5 at 4:56

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.