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

According to the comments in Xen's network-bridge script, the process of starting the bridge with external interface eth0 is thus:

# Creates the bridge
# Copies the IP and MAC addresses from eth0 to veth0
# Renames eth0 to be peth0
# Renames veth0 to be eth0
# Enslaves peth0, veth0 to bridge

NOTE: that doesn't actually seem to be what the script does. For the last step, it looks like it actually enslaves peth0 and vif0.0 to the bridge, but I don't know if that is important to my question.

Why the shuffle? Would it not be equivalent to rename veth0 to peth0 and then eth0 to veth0? I think I am missing something important, but I just don't see it.

share|improve this question

The goal is to maintain 'eth0' IP/MAC for the host OS but not have the physical interface tied to a particular IP. This allows guest to not need NAT for their network.

The rename game is to minimize the down time of the network, reduce the number of things that can go wrong at the last minute and provide an easy way to back out should something go wrong.

share|improve this answer
Okay, this helps, and I think I am getting closer. So I guess Xen's desire is to have dom0 be able to maintain the name "eth0" as it's primary interface, but switch it to a virtual interface, kind of like the virtual interface that the domUs are bound to (e.g. vif0.1). I guess my next question will be about routing :) – Chad Huneycutt Jul 18 '09 at 6:31

Your renaming scheme wouldn't work because peth0 is "Physical eth0", and your way you'd end up with peth0 being the virtual interface.

Honestly, I think Xen's bridging stuff is utter balls, and I just use the OS' native bridging configuration setup (/etc/network/interfaces makes this beautifully easy), and then just tell the domU's config which bridge to attach to. I also name all my bridges with meaningful names (which helps because we've got VLANs everywhere, and they're all meaningfully named too).

share|improve this answer
I think I am having trouble understanding whether physical or virtual even matters inside a bridge, since it is all mixed together. I imagine I will end up doing the bridge myself as well once I figure this out, because, like you, I intend to trunk vlans to the dom0 ultimately. – Chad Huneycutt Jul 18 '09 at 6:33
I tend to think of a bridge as just like a switch, with the physical interface just a network cable to another switch, and the virtual NICs (and the interface associated with the bridge) as the cables to the NICs for the various physical and virtual machines. – womble Jul 18 '09 at 7:31

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.