Proxmox Networking VM with Public IP cannot ping from Proxmox Host

noeprivacy

Member
Nov 13, 2015
6
0
21
Indonesia
Hi there, i new using proxmox and i want to learn about proxmox.. i have some problem with proxmox networking please help..




i have 3 server A, B, C. And i have 5 IP for it, 10.0.0.18 - 10.0.0.22 (10.0.0.16/29, Useable 10.0.0.18 - 10.0.0.22)


this is the server A IP:
10.0.0.18 for eth0
10.0.0.20 for vmbr1 (bridge)
10.0.0.21 for VM


this is the server B IP:
10.0.0.19 for eth0


this is the server C IP:
10.0.0.22 for eth0


ping from server B to server A is work fine, also from C to B, A (18) to B, A (18) to C.


and my problem is, i can't ping from server B (19) to VM at server A (21).
and ping from VM at server A (21) to server B (19) is host unreachable.


and this is my network interface from server A:
# network interface settings
auto lo
iface lo inet loopback


auto eth0
iface eth0 inet static
address 10.0.0.18
netmask 255.255.255.248
gateway 10.0.0.17
post-up echo 1 > /proc/sys/net/ipv4/conf/eth0/proxy_arp


iface eth1 inet manual


auto vmbr0
iface vmbr0 inet static
address 192.168.1.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 '192.168.1.0/24' -o eth0 -j MASQUERADE
post-down iptables -t nat -D POSTROUTING -s '192.168.1.0/24' -o eth0 -j MASQUERADE


auto vmbr1
iface vmbr1 inet static
address 10.0.0.20
netmask 255.255.255.248
bridge_ports none
bridge_stp off
bridge_fd 0


up ip route add 10.0.0.21/32 dev vmbr1
what i make some mistakes?
how to make it can work?




waiting for advice, thank you
 
Hi,
your Vm on which vmbr it is?
It must be on vmbr1.
and your vmbr1 need a default route.
 
I already have many trial to the interfaces. The first step i test:
Step 1:
Use this interface setting
# network interface settings
auto lo
iface lo inet loopback


auto eth0
iface eth0 inet static
address 10.0.0.18
netmask 255.255.255.248
gateway 10.0.0.17
post-up echo 1 > /proc/sys/net/ipv4/conf/eth0/proxy_arp


iface eth1 inet manual


auto vmbr0
iface vmbr0 inet static
address 192.168.1.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 '192.168.1.0/24' -o eth0 -j MASQUERADE
post-down iptables -t nat -D POSTROUTING -s '192.168.1.0/24' -o eth0 -j MASQUERADE


auto vmbr1
iface vmbr1 inet static
address 10.0.0.20
netmask 255.255.255.248
bridge_ports none
bridge_stp off
bridge_fd 0

with this setting the VM can access internet with private IP (192.168.1.0/24) and can ping to any other website. But the public IP (10.0.0.0/24) cannot ping to host and also to gateway and also to any other website.

Step 2:
i use this setting:
# network interface settings
auto lo
iface lo inet loopback




auto eth0
iface eth0 inet static
address 10.0.0.18
netmask 255.255.255.248
gateway 10.0.0.17
post-up echo 1 > /proc/sys/net/ipv4/conf/eth0/proxy_arp




iface eth1 inet manual




auto vmbr0
iface vmbr0 inet static
address 192.168.1.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 '192.168.1.0/24' -o eth0 -j MASQUERADE
post-down iptables -t nat -D POSTROUTING -s '192.168.1.0/24' -o eth0 -j MASQUERADE




auto vmbr1
iface vmbr1 inet static
address 10.0.0.20
netmask 255.255.255.248
bridge_ports eth0
bridge_stp off
bridge_fd 0
the VM with public (10.0.0.0/24) can ping to any other website, but VM with private IP (192.168.1.0/24) cannot ping to any destination.




How to make it work?
The first VM using Private IP
The second VM using Public IP
how to set it up can work with this network configuration?
all solution will be appriciate, thank you
 
Hi,
your Vm on which vmbr it is?
It must be on vmbr1.
and your vmbr1 need a default route.

thank you for your reply wolfgang.

I test it with two VM..
the first i use vmbr0, and other VM i use vmbr1

so, it have 2 VM with public and private IP..
with interface setting at the first time, i can ping VM with private ip without any problem, but i can't ping to other proxmox host with VM attach public ip..

i think i wrong on routing at Server A.
 
anyone have a suggestion to me?
i'm confuse about this..



now i just have one problem with this. VM 2 at Server A (10.0.0.21/29) cannot ping to Server B (10.0.0.19/29)
Server A (10.0.0.18/29)
- VM 1 (vmbr0, Private, Can access internet) (192.168.1.10/24)
- VM 2 (vmbr1, Public, Can access internet) (10.0.0.21/29)

Server B (10.0.0.19/29)

Server A (10.0.0.19/29), Server B (10.0.0.19/29), VM 2 (10.0.0.21/29) (It's same subnet)

What proxmox with vmbr1 cannot see out of they network?
If can, how to configure that routing so the VM 2 can ping the Server B?
 

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!