Apologies for the really basic question, but after setting up an LXC using ubuntu-24.04-2 template I have noticed that it is not picking up the default gateway. The only change to defaults was basically choosing DHCP instead of static for IPv4. I noticed proxmox seems to know how the distro manages networking and generates some files:
I can ping the internal network and lookup works, but cannot get to the internet due to missing default route:
Note that 192.168.9.253 is the gateway running OPNSense. I use DNSMasq and have option 121 set for the internal routes, but nothing to specify the default route. I expect this is provided by default as other devices seem to be able to configure themselves properly.
What other network configuration does Proxmox generate and what should I look at?
EDIT: I am now sure it is not OPNSense as I noticed in the log:
Code:
root@try1:~# cat /etc/systemd/network/eth0.network
[Match]
Name = eth0
[Network]
Description = Interface eth0 autoconfigured by PVE
DHCP = ipv4
IPv6AcceptRA = false
root@try1:~# cat /etc/resolv.conf
# --- BEGIN PVE ---
search ad.home.lan
nameserver 192.168.9.201
# --- END PVE ---
I can ping the internal network and lookup works, but cannot get to the internet due to missing default route:
Code:
root@try1:~# nslookup www.proxmox.com
Server: 192.168.9.201
Address: 192.168.9.201#53
Non-authoritative answer:
Name: www.proxmox.com
Address: 212.224.123.69
Name: www.proxmox.com
Address: 2a01:7e0:0:424::12
root@try1:~# ping www.proxmox.com
ping: connect: Network is unreachable
root@try1:~# ip route
192.168.9.0/24 dev eth0 proto kernel scope link src 192.168.9.187 metric 1024
192.168.9.10 dev eth0 proto dhcp scope link src 192.168.9.187 metric 1024
192.168.9.253 dev eth0 proto dhcp scope link src 192.168.9.187 metric 1024
192.168.42.0/24 via 192.168.9.10 dev eth0 proto dhcp src 192.168.9.187 metric 1024
192.168.43.0/24 via 192.168.9.10 dev eth0 proto dhcp src 192.168.9.187 metric 1024
Note that 192.168.9.253 is the gateway running OPNSense. I use DNSMasq and have option 121 set for the internal routes, but nothing to specify the default route. I expect this is provided by default as other devices seem to be able to configure themselves properly.
What other network configuration does Proxmox generate and what should I look at?
EDIT: I am now sure it is not OPNSense as I noticed in the log:
Code:
Oct 06 11:19:01 systemd-networkd[117]: eth0: DHCPv4 address 192.168.9.187/24, gateway 192.168.9.253 acquired from 192.168.9.253
Last edited: