How to setup Multiple NIC with Multiple route/gateway

W

wally

Guest
I have seen variations of questions and answers around the forum but none addressing how to have 2 routed network in Proxmox. I am trying to find a way to have a gateway for each of the 2 Nic on my master server.

I have a network 192.168.168.0 = eth0 (vmbr0) this is the default network
10.10.10.0 = eth1 (vmbr1) based on the set up and docs so far this is set to route via 192.168.168.0 network

I would like to have 10.10.10.0 network go through a different router because as things are right now I cannot pass traffic from outside (meaning when I try to get to my servers on 10.10.10.x) via internet.

I have 2 routers 1 for 192.x.x.x the other for 10.x.x.x so what would I need to put in the /etc/network/interfaces so instead of this:

Kernel IP routing table
Destination Gateway Genmask Flags MSS Window irtt Iface
192.168.168.0 0.0.0.0 255.255.255.0 U 0 0 0 vmbr0
10.10.10.0 0.0.0.0 255.255.255.0 U 0 0 0 vmbr1
0.0.0.0 192.168.168.1 0.0.0.0 UG 0 0 0 vmbr0


I would like to see:
Kernel IP routing table
Destination Gateway Genmask Flags MSS Window irtt Iface
192.168.168.0 0.0.0.0 255.255.255.0 U 0 0 0 vmbr0
10.10.10.0 10.10.10.1 255.255.255.0 U 0 0 0 vmbr1
0.0.0.0 192.168.168.1 0.0.0.0 UG 0 0 0 vmbr0

This is /etc/network/interfaces presently:
# network interface settings
auto lo
iface lo inet loopback

iface eth0 inet manual

iface eth1 inet manual

auto vmbr0
iface vmbr0 inet static
address 192.168.168.25
netmask 255.255.255.0
gateway 192.168.168.1
bridge_ports eth0
bridge_stp off
bridge_fd 0

auto vmbr1
iface vmbr1 inet static
address 10.10.10.25
netmask 255.255.255.0
bridge_ports eth1
bridge_stp off
bridge_fd 0


I would appreciate some information on doing this, I am starting to feel like what I am trying to do is not supported,, but I know this can be done on regular unix/linux. Please respond with specifics on what needs to be done. Thanks.
 
Hi,
your routing entry, which you would see makes no sense. Because vmbr1 is allready in the 10.10.10.0/24-Network - so there is no routing entry needed to reach an adress in this network.

You can do something like this:
ip route add 10.10.20.0/24 via 10.10.10.1
But this don't help to resolve adresses from outside - this is for the default entry. (perhaps you must nating (ugly) the outside-traffic on the 10.10.10.1-router?!

Udo
 
Didn't quite understand, should I be putting "ip route add 10.10.20.0/24 via 10.10.10.1" in the /etc/network/interfaces file or somewhere else. Here is some more details.
I have 192.x.x.x as a wired network so the cord from the proxmox master goes to the wired router
I have 10.x.x.x as a wireless network so the cord from the proxmox master goes to a wireless router (mainly to get to it from outside)
Both routers have WAN interfaces but I notice I cannot get to anything on the 10.x.x.x if I am not using the proxmox consoles as oppose to when I get in on the wired one I can move around internally on 192.x.x.x.
I have internal DNS/DHCP servers on both network (they are VM ) and they work well, but I think the think I've noticed on the 10. segment is I can hit the individual devices there but there is no way they are getting back to me - I suspect because of the default gw which points to 192.x.x.1 which is the wired router.
Any suggestions on trying to get this set up so i can have the 2 distinct routed network hosted from my proxmox cluster.
 
No one out there doing or thinking of this sort of layout willing to share???
 
You are trying to access Web console on ip 192.168.168.25 through wireless router on 10.10.10.0/24 subnet which is physically completely separated from wired router?

eth0/vmbr0 [192.168.168.0/24]---------------------->[wired router]----------wan-public-ip1


eth1/vmbr1[10.10.10.0/24]--------------------------->[wireless router]<------wan-public-ip2
 
Yes I know, based on all the docs and setup that seem to be the suggestion. This is on the cluster master remember so the question I have been asking all along is how I keep both interfaces on this one server (master) separate i.e having separate gateway etc. Any thoughts?
 
Did you ever get this issue resolved? I believe I'm trying to do much the same thing or similar, & I'm not having any luck with it. Did you?
 

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!