Server Fault is a question and answer site for system and network administrators. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

running xen with 2 guests

i have been trying to assign public ip addresses to two virtual nic, one each which is sharing bridge networking with host.

tried this

Host x.x.116.2

created two nic on guest which is using same bridge with host

eth0 x.x.116.3
eth1 x.x.116.4

but at a time only one is active,how can i enable both

share|improve this question
up vote 1 down vote accepted

You are better off just aliasing the .4 to the eth0 interface and not placing it on it's separate interface since they are the same subnet.

ifconfig eth0:1 x.x.116.4 netmask
share|improve this answer
mike could u tell me,why this will not work,if we assign ip of same sub net. – kevin Mar 5 '13 at 6:56
because you probably gave it a /24 so the kernel will send all traffic out eth0 for .4 and it won't like coming back in via eth0.. You can do it but it requires a lot of tricky ip route commands. Why are you even doing multiple interfaces anyway? If you use multiple ips on the same subnet.. it should be aliased – Mike Mar 5 '13 at 7:04
Interface aliases are deprecated, as is ifconfig on linux. The same effect can be achieved more naturally with ip addr add x.x.116.4/24 dev eth0. – BatchyX Mar 5 '13 at 8:39

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.