multiple netw

czirjak

New Member
Aug 12, 2011
5
0
1
Hi,

I have a C class network with more vlan.
My proxmox server has got 4 nic. I want to place my virtual server to different vlan.
How can i do it?

Thanks.
 
Hi,

I have a C class network with more vlan.
My proxmox server has got 4 nic. I want to place my virtual server to different vlan.
How can i do it?

Thanks.
Hi,
normaly you create for each vlan an bridge - can be named like the vlan like vmbr50 for vlan50. So you can add a virtual nic to the VM.
The pve-host doesn't need an ip on the bridge.
With your 4 NICs it's on you, to choice the best config:

Each vlan use an own NIC
You use one (or more) NIC for vlan-tagging
You can bond 2 (or more) NICs for better performance
You can also do vlan-tagging on bonds, but someone has reported trouble with this - this depends on the switch which must handle this right.

What's about someting like this:
eth0 - for vmbr0 (cluster-communication).
eth1 - vlan-tagging only, for most networks (eth1.10 -> vmbr10, eth1.20 -> vmbr20, ...)
eth2+3 bond for hi-traffic network.

If you whant to use DRBD for cluster-storage you should also use an dedicated NIC for that (but for DRBD is 10GB much better ;) )

Udo
 
Last edited:
I want that one nic use one vlan.


nic1----------------------> switch (vlan1) Virtual servers in vlan1 use nic1.
nic2----------------------> switch (vlan2) Virtual servers in vlan2 use nic2.

I test this configs
1.
iface eth0 inet manual
iface eth1 inet manual
iface eth2 inet manual
iface eth3 inet manual
auto vmbr0
iface vmbr0 inet static
address 10.14.47.194
netmask 255.255.255.240
gateway 10.14.47.206
bridge_ports eth0
bridge_stp off
bridge_fd 0

auto vmbr1
iface vmbr1 inet manual
bridge_ports eth1 (I plug in eth1 etherneth cable in vlan2 port of switch.)
bridge_stp off
bridge_fd 0

In this case if i configure the virtual server ip address to vlan2 it doesnt work.

2. if I set one ip for vmbr1 from vlan2 in this way:

iface vmbr1 inet static
address 10.14.47.189 (ip from vlan2 range)
netmask 255.255.255.192
gateway 10.14.47.190
bridge_ports eth1
bridge_stp off
bridge_fd 0
then I can configure virtual server ip address with vlan2 ip and is network but the proxmox server lost its connection.
 
Oh, everything good.
The first config is ok but I plugd in not eth1 in the switch.

Thanks.