How to configure bridged network

falves1

Well-Known Member
Jan 11, 2009
99
3
48
I downloaded and uploaded the template centos-5-x86_64-default-5.2-20090108.tar.gz, and created a VE from it, with bridged networkinf. When I open the VNC console, I type setup and I cannot see any networking option. How do I assign an IP address, or actually two, to my new VE?
 
I downloaded and uploaded the template centos-5-x86_64-default-5.2-20090108.tar.gz, and created a VE from it, with bridged networkinf. When I open the VNC console, I type setup and I cannot see any networking option. How do I assign an IP address, or actually two, to my new VE?

if you use brigded networking in a container you need to configure IP addresses like on a physical host - you need to create the network configuration files inside the container manually (refer to the centos docu).
(the templates are "optimized" for virtual networking).

is there a special reason for brigded networking? if not, just use virtual network where you can specify the IP on the host side.
 
Bridged

I have been a user of Virtuozzo for a long time and the problem is that if you use virtual networking then you can actually use one single network, and I have many. If you try to use more than one network, then the default gateway from network "A" appears to be used for VE's with IP's from network "B".

In any case, how do I chnage from one network mode to the other?

I cannot figure out how to assign the IP address, mask and default gateway for the VE in brided mode. In Virtuozzo there is a Management Console where you manage the network for the container, either bridged or virtual. Could you please do some research? I need to solve this.
By the way, I windows 2003 R2 SP2, if you create a second Ethernet device (Virtio), the machine does not boot anymore. It just fails. And another question: is there any way to upgrade the KVM version used in Promox to tehh current one? The SMP overhead is awful.
 
Last edited:
I have been a user of Virtuozzo for a long time and the problem is that if you use virtual networking then you can actually use one single network, and I have many. If you try to use more than one network, then the default gateway from network "A" appears to be used for VE's with IP's from network "B".

In any case, how do I chnage from one network mode to the other?

I cannot figure out how to assign the IP address, mask and default gateway for the VE in brided mode. In Virtuozzo there is a Management Console where you manage the network for the container, either bridged or virtual. Could you please do some research? I need to solve this.

A good start point for understanding OpenVZ networking capabilities:
http://wiki.openvz.org/Category:Networking

By the way, I windows 2003 R2 SP2, if you create a second Ethernet device (Virtio), the machine does not boot anymore. It just fails. And another question: is there any way to upgrade the KVM version used in Promox to tehh current one? The SMP overhead is awful.

I confirm this issue with 2 virtio, thanks for reporting (use e1000 instead).
Testing of KVM-82 is in progress here - with better smp support for win guests and also the virtio issue with 2 cards seemed fixed here.
 
Need help with bridged networking

I want to add a new veth interface for my VE 102, in the bridge vmbr0 as my windows virtual box, so they can exchange data diretcly. But there is an error.

vzctl set 102 --netif_add veth102.0, 00:12:34:56:78:9A, eth0, 00:12:34:56:78:9B --save
Saved parameters for CT 102
kvm:~# ifconfig veth102.0 0
SIOCSIFADDR: No such device
veth102.0: ERROR while getting interface flags: No such device

Also the easymac.sh script mentioned in the wiky is not there.

Would you be so kind as to publish an easy way to get a veth interface atached the default bridge? Actually, this should be donde from the web interface. The least we have to log into the Promox via SSH the better.
 
I want to add a new veth interface for my VE 102, in the bridge vmbr0 as my windows virtual box, so they can exchange data diretcly. But there is an error.

vzctl set 102 --netif_add veth102.0, 00:12:34:56:78:9A, eth0, 00:12:34:56:78:9B --save
Saved parameters for CT 102
kvm:~# ifconfig veth102.0 0
SIOCSIFADDR: No such device
veth102.0: ERROR while getting interface flags: No such device

pls see also this: http://pve.proxmox.com/wiki/Network_Model

Also the easymac.sh script mentioned in the wiky is not there.

I do not know this script, why do you need this?

Would you be so kind as to publish an easy way to get a veth interface atached the default bridge? Actually, this should be donde from the web interface. The least we have to log into the Promox via SSH the better.

I do not see what you miss here. If you create a container you can choose between brigded (veth) and virtual (venet) networking.

if you choose veth, you need to configure networking inside the container.

if you choose venet (default), you can configure networking on the Proxmox management interface.
 
Error inside the container wit bridged betwork

I get an error when configuring venet0 inside the container:

cat ifcfg-venet0
DEVICE=venet0
BOOTPROTO=static
ONBOOT=yes
IPADDR=105.78.162.49
NETMASK=255.255.255.0
BROADCAST=0.0.0.0
GATEWAY=105.78.162.1 service network restart
Shutting down interface venet0: [ OK ]
Shutting down loopback interface: [ OK ]
Bringing up loopback interface: [ OK ]
Bringing up interface venet0: error in ifcfg-venet0:0: didn't specify device or ipaddr RTNETLINK answers: File exists

Also I would like to upgrade right away to the latest version of KVM, since my application is a telephony project and needs SMP support but the overhead in the current version makes it useless. For instance, with 8 processors it takes 20 mins to load and with 2 processors it takes 5. But I need 8 processors because when the calls start flowing the amount of processing takes the processors to 100%.

Would you be so kind as to help me configure the bridged network inside my VE?
The IP address is 105.78.162.49, 255.255.255.0, GW=105.78.162.1. What would the files inside the VE look like?
 
I get an error when configuring venet0 inside the container:

you need to configure venet on the Proxmox management interface (not inside the container)

Also I would like to upgrade right away to the latest version of KVM, since my application is a telephony project and needs SMP support but the overhead in the current version makes it useless. For instance, with 8 processors it takes 20 mins to load and with 2 processors it takes 5. But I need 8 processors because when the calls start flowing the amount of processing takes the processors to 100%.

testing of KVM-82 is in progress, will be released as soon as we finished testing.

Would you be so kind as to help me configure the bridged network inside my VE?
The IP address is 105.78.162.49, 255.255.255.0, GW=105.78.162.1. What would the files inside the VE look like?

if you use bridged networking, you need to configure the network as you do it on a physical host (inside) - nothing special for Proxmox VE.
 
Problem with bridged networking

You keep replying that but I already showed you the error message I get when I try to configure the file ifcfg-venet0. I know Centos pretty well and I am at a loss as how to configure the network inside. If you cannot support me on this then what do I do? Find another solution an do not use Promox?
 
You keep replying that but I already showed you the error message I get when I try to configure the file ifcfg-venet0. I know Centos pretty well and I am at a loss as how to configure the network inside. If you cannot support me on this then what do I do? Find another solution an do not use Promox?

sorry, but it looks like you are confused :)

you cannot configure venet inside the centos container - as already described. you need to configure this on the Proxmox interface.

clear now?
 
Problem with bridged networking

Let's take a step back. I am confused. I create the VE and choose bridged networking. Then I log into the VE and how exactly do I add my three elements, IP address, MASk and Default gateway?
I tried editing ifcfg-venet0 and when I issue a 'service network restart" it fails with an error, which I posted. So how exactly would I do this? Would you be so kind as to post an example? Here in the US in any enterprise we have severla different networks, and the only way to make them all work toghether in Virtuozzo or OpenVZ is to use bridged networking. Thanks for your patience.

inside the VE there is no file like icfg-eth0, etc. That's why I am asking.
 
Last edited:
Let's take a step back. I am confused. I create the VE and choose bridged networking. Then I log into the VE and how exactly do I add my three elements, IP address, MASk and Default gateway?
I tried editing ifcfg-venet0 and when I issue a 'service network restart" it fails with an error, which I posted. So how exactly would I do this? Would you be so kind as to post an example? Here in the US in any enterprise we have severla different networks, and the only way to make them all work toghether in Virtuozzo or OpenVZ is to use bridged networking. Thanks for your patience.

inside the VE there is no file like icfg-eth0, etc. That's why I am asking.

yes, there is no icft-eth0 file in such templates. you need to create them manually as I posted (you can copy these files from a physical centos installation).

centos: if you do not know which network configuration files are necessary, post to a centos forum. here is the place primarily for Proxmox VE related issues, but we try to give the right hints for other distro´s.
 
Question

I have dozens of Centos machines, but how am I going to copy the files if the network does not work? Please help me find a workaround, since many people are going to face the same issue. Meybe there should be a template for for bridged networking and another one for virtual networking, or a way to create the scripts at the time when the template is applied and the VE created.
 
I have dozens of Centos machines, but how am I going to copy the files if the network does not work?

we talk here about OpenVZ. therefore you can access the container also if you have no network in the container - one of the cool OpenVZ features.

login to the Proxmox VE console via ssh and:

Code:
vzctl enter VMID

maybe you take a look on all OpenVZ features by reading their wiki pages.
 
Solved

I already succeeded. Just copied the entire dir /etc/sysconfig/network-scrips from a running Centos and changed the IP address, and voila! it worked.
 
I would suggest using smb/cifs because you have a windows machine the will be sharing documents. It is easy to setup, and supported by freenas, OS x, and winblows
 

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!