Proxmox 4 , VM have Two NIC , public IP and private IP , can not ping e

mfaridi

Renowned Member
Oct 17, 2015
85
0
71
I install Proxmox 4 and I have 4 VM , OpenBSD , FreeBSD , ubuntu and Centos , and I add two NIC for each VM , my Promox 4 has two NIC , one NIC with public IP and one NIC with private IP , this is my
Code:
root@aal-prox:~# cat /etc/network/interfacesauto lo
iface lo inet loopback


auto vmbr0
iface vmbr0 inet static
    address 8.8.8.200
    netmask 255.255.255.0
    gateway 8.8.8.1 
    bridge_ports eth0
    bridge_stp off
    bridge_fd 0


auto vmbr1
iface vmbr1 inet static
        address  192.168.0.200
        netmask  255.255.255.0
        gateway  192.168.0.91
        bridge_ports  eth1
        bridge_stp off
        bridge_fd  0
at each VM , private IP connect to vmbr1 and public IP connect to vmbr0 , my problem is this , when client has private IP , can connect to VM only with private IP and if client has public IP only can connect to VM with public IP.
for example if my system has 192.168.0.44 and want connect to Centos with 192.168.0.202 , my system and Centos can connect and I can ssh to Centos in VM , if my next interface in Centos has 8.8.8.8 , I can not connect to 8.8.8.8 with 192.168.0.44 .
if my system has 192.168.0.44 I can not connect 8.8.8.8 and can not ping it , for ping I must change IP to 8.8.8.7 and then I can connect to Centos with 8.8.8.8.
this is happen for all my VM and .
another example I installed apache server on ubuntu , if my client has 192.168.0.44 and type 192.168.0.203 , he or she can see apache default page , if my client type 8.8.8.203 in Firefox , he or she can not see apache default web page . my Centos in VM has 192.168.0.203 and 8.8.8.203 IPs.
I do not know when I want connect to Proxmox UI with web , I must type in Firefox 8.8.8.200;8006. and when I type 192.168.0.200:8006 I can not connect to web interface .
 
Last edited:
Please help to me to solve this problem

I do not have this problem with ESXi
 
Last edited: