second eth interfaces for VM

myke1124

New Member
Nov 3, 2009
5
0
1
My Proxmox VE host has 2 eth interfaces.
I have eth0 bridged to vmbr0.
I have eth1 bridged to vmbr1.
I can assign either bridge to any virtual machine on eth0.
I would like to be able to assign vmbr0 as eth0 and vmbr1 as eth1 to the same virtual machine. I have not found a way to accomplish this via the web interface.

This is what I have set on the host machine:
Code:
# cat /etc/network/interfaces 
auto lo
iface lo inet loopback

auto vmbr0
iface vmbr0 inet static
    address 10.30.1.5
    netmask 255.255.255.0
    gateway 10.30.1.1
    bridge_ports eth0
    bridge_stp off
    bridge_fd 0

auto vmbr1
iface vmbr1 inet static
    address 10.20.254.254
    netmask 255.255.255.0
    bridge_ports eth1
    bridge_stp off
    bridge_fd 0
Code:
# brctl show
bridge name    bridge id           STP enabled    interfaces
vmbr0          8000.00221964feff   no             eth0
                                                  veth101.0
vmbr1          8000.00221964ff01   no             eth1
Based on `brctl show` it indicates that I need to add veth101.1 to vmbr1.
Before I can add veth101.1 to the bridge, I need to create that interface. How do I create this virtual interface? or Am I going about this the wrong way?
 
The NIC ordering is under control of the VM - usually you can set the order with udev inside the VM.
 
i'm running a similar setup, where all proxmox hosts are connected with two independent NICs and networks.
Code:
eth0 -> vmbr0 = external network
eth1 -> vmbr1 = storage network
so it basically looks like your setup.
for my KVM machines i can add virtual ethernet hardware and assign two virtual NICs to the bridges with the web-gui.

for my OpenVZ machines this can't be done with the web-gui (feature request). so i've configured 2 veth devices by hand. and added them do my /etc/vz/conf/<VID>.conf while the container was stopped.

Code:
NETIF="ifname=eth0,bridge=vmbr0,mac=00:00:00:01:09:00,host_ifname=veth109.0,host_mac=00:01:00:01:09:00;ifname=eth1,bridge=vmbr1,mac=00:00:00:01:09:01,host_ifname=veth109.1,host_mac=00:01:00:01:09:01"
that way eth0 of the host and VM are connected as
well as eth1 of the host and VM are connected.

network config of the VM is done inside of it with the means of your distribution.
 
i'm running a similar setup, where all proxmox hosts are connected with two independent NICs and networks.
Code:
eth0 -> vmbr0 = external network
eth1 -> vmbr1 = storage network
so it basically looks like your setup.
for my KVM machines i can add virtual ethernet hardware and assign two virtual NICs to the bridges with the web-gui.

for my OpenVZ machines this can't be done with the web-gui (feature request). so i've configured 2 veth devices by hand. and added them do my /etc/vz/conf/<VID>.conf while the container was stopped.

Code:
NETIF="ifname=eth0,bridge=vmbr0,mac=00:00:00:01:09:00,host_ifname=veth109.0,host_mac=00:01:00:01:09:00;ifname=eth1,bridge=vmbr1,mac=00:00:00:01:09:01,host_ifname=veth109.1,host_mac=00:01:00:01:09:01"
that way eth0 of the host and VM are connected as
well as eth1 of the host and VM are connected.

network config of the VM is done inside of it with the means of your distribution.

This really Works... Thanks...
Hope ProxmoxVE - OpenVZ should create web-gui of this.
 
This really Works... Thanks...
Hope ProxmoxVE - OpenVZ should create web-gui of this.

Good day.

Sorry for my english, im use tool translate.

what are the settings of the virtual machines network?
example
eth0---vmbr0
vmbr0=192.168.0.x/24 /gateway 192.168.0.1

eth1---vmbr1
vmbr1=192.168.1.x/24 /geteway 192.168.1.1


vm1 ---- ip address/mask/gateway if is necessary?¿With what virtual nics?
etc...

I dont understand...

thanks
 

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!