multiple Networks on single NIC (OVH vRack)

Carsten Bleek

Active Member
Sep 29, 2016
11
0
41
53
cross-solution.de
I'm a running proxmox 4.4 cluster in an OVH vRack. Public IPs are assigned to the nodes at eth0, an IP block is assigned to the vRack which reaches the nodes on eth1.

Everythings works fine.

I've added a second network to the vRack, which reaches eth1 and I have the problem, that I can't use the second network within a VM.

Problem ist probably a lack of network knwoledge. But maybe somebody can help.

My current configuration:

auto lo
iface lo inet loopback

iface eth0 inet manual

iface eth1 inet manual

auto vmbr1
iface vmbr1 inet static
address xxx
netmask xxx
bridge_ports eth1
bridge_stp off
bridge_fd 0
post-up /etc/pve/kvm-networking.sh

auto vmbr0
iface vmbr0 inet static
address xxx
netmask xxx
gateway xxx
broadcast xxx
bridge_ports eth0
bridge_stp off
bridge_fd 0
network xxx


# internal network, which is working
auto vmbr2
iface vmbr2 inet static
address xxx
netmask xxx
bridge_ports eth1.1
bridge_stp off
bridge_fd 0
bridge_vlan_aware yes
#Intern

# bridge, which was added to get the second netword (not working)
auto vmbr3
iface vmbr3 inet manual
bridge_ports none
bridge_stp off
bridge_fd 0
post-up /sbin/ip route add table vlan2 default via xxx dev vmbr3
post-up /sbin/ip rule add from xxx table vlan2
post-down /sbin/ip route del table vlan53 default via xxx dev vmbr3
post-down /sbin/ip rule del from xxx table vlan2


Does anybody has best practice tips, how to use multiple networks within a OVH vRack?

 
so I understand you right the VMs which have a NIC connected to the vmbr3 can talk to each other inside vmbr3 but cannot talk to the outside world ?
I think vmbr3 should either have an IP adress if you want to do routing, or have a bridge port set a physcal device like you did your the vmbr2 bridge
 
Yes, vmbr3 cannot talk to the outside world.

I assume, that I have to use routing, if I have only one physical device. I've added an IP of my /27 net to the vmbr3. I can ping a container using the vmbr3 from the host. I can see a Ping from the outside world to the container on the eth1 of the host using tcpdump. Within the container, I cannot see the ping. So it's propably a routing problem.

I think I have to route everything arriving on eth1 to my /27 net to the x.x.x.225 (which I've assigned to the vmbr3), Everything from the vmbr3 to to the ouside world I've to route to x.x.x.254 (which I got from OVH) over eth1.

root@node4:~# ip route get x.x.x.254
147.135.172.254 dev vmbr3 table rt147 src x.x.x.225
cache


vmbr3 of my /etc/network/interfaces looks like

auto vmbr3
iface vmbr3 inet static
address x.x.x.225
netmask 255.255.255.224
bridge_ports none
bridge_stp off
bridge_fd 0
post-up echo 1 > /proc/sys/net/ipv4/ip_forward
post-up ip route add x.x.x.224/27 dev vmbr3 src x.x.x.225 table rt147
post-up ip route add default via x.x.x.225 dev vmbr3 table rt147
post-up ip rule add from x.x.x.225/27 table rt147
post-up ip rule add to x.x.x.225/27 table rt147


Any Idea?
 

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!