No internet connectivity for VMs

Reuven

Member
Oct 22, 2019
73
2
11
58
Hi and thanks for your help.

I have no networking for my first VM in my new Proxmox 6.2 installation.....here is my /etc/network/interfaces :

auto lo
iface lo inet loopback

iface enp8s0 inet manual

auto vmbr0
iface vmbr0 inet static
address 88.198.26.141/27
gateway 88.198.26.129
bridge-ports enp8s0
bridge-stp off
bridge-fd 0
bridge-vlan-aware yes
bridge-vids 2-4094

I need NAT and an DHCP server to assign private IPs to my VMs when they boot...

Thanks in advance
 
Hi. Thanks for your reply and help.

I did check Masquerading (NAT) with iptables?

but I am a little confused. let me explain:

in my /etc/network/interfaces the vmbr0 appears to have my only public IP address while in the Masquerading (NAT) with iptables the vmbr0 has the private subnet assigned to it....


(this is my /etc/network/interfaces)

auto lo
iface lo inet loopback

iface enp8s0 inet manual

auto vmbr0
iface vmbr0 inet static
address 88.198.26.141/27
gateway 88.198.26.129
bridge-ports enp8s0
bridge-stp off
bridge-fd 0
bridge-vlan-aware yes
bridge-vids 2-4094

but in the Masquerading (NAT) with iptables example it is the opposite

auto lo
iface lo inet loopback

auto eno1
#real IP address
iface eno1 inet static
address 198.51.100.5
netmask 255.255.255.0
gateway 198.51.100.1

auto vmbr0
#private sub network
iface vmbr0 inet static
address 10.10.10.1
netmask 255.255.255.0
bridge_ports none
bridge_stp off
bridge_fd 0

post-up echo 1 > /proc/sys/net/ipv4/ip_forward
post-up iptables -t nat -A POSTROUTING -s '10.10.10.0/24' -o eno1 -j MASQUERADE
post-down iptables -t nat -D POSTROUTING -s '10.10.10.0/24' -o eno1 -j MASQUERADE


Now, I ask, from the start my installation did not give my new VM internet connectivity, is this normal? or should i reinstall proxmox?

with any other virtualization solution, for example in Hyper-v, you get automatic nat and dhcp with the "Default switch"

also in vmware....that is why i ask...maybe there is something wrong with my installation...

all the best Reuven
 
Just to add this information...maybe it is relevant... my server is hosted at hetzner ..I installed proxmox 6.2 using the proxmox ISO....
 
Reuven, Hetzner is very very relevanat, they block all mac addresses which is not the one from the host itself. You need to route through the host and maybe (from i heard) MTU 1400 on the bridge and inside the vm.

Please search the forum for Hetzner, you will find lots of infos.
 
  • Like
Reactions: Moayad

About

The Proxmox community has been around for many years and offers help and support for Proxmox VE, Proxmox Backup Server, and Proxmox Mail Gateway.
We think our community is one of the best thanks to people like you!

Get your subscription!

The Proxmox team works very hard to make sure you are running the best software and getting stable updates and security enhancements, as well as quick enterprise support. Tens of thousands of happy customers have a Proxmox subscription. Get yours easily in our online shop.

Buy now!