Xen Bridge Loop: Difference between revisions
Lars.kurth (talk | contribs) (Created page with "<!-- MoinMoin name: XenBridgeLoop --> <!-- Comment: --> <!-- WikiMedia name: XenBridgeLoop --> <!-- Page revision: 00000001 --> <!-- Original date: Fri Aug 8 02:48:36…") |
Rcpavlicek (talk | contribs) |
||
(3 intermediate revisions by 3 users not shown) | |||
Line 11: | Line 11: | ||
= Bridged Network under Xen Overview = |
= Bridged Network under Xen Overview = |
||
Xen uses bridged network by default. For detail, see: [[ |
Xen uses bridged network by default. For detail, see: [[Xen Networking]]. |
||
= Why STP is turned off? = |
= Why STP is turned off? = |
||
Line 25: | Line 25: | ||
There is a loop in switch0 and xenbr0: |
There is a loop in switch0 and xenbr0: |
||
<pre |
<pre> |
||
+-----------------------------------+ |
+-----------------------------------+ |
||
| switch0 | |
| switch0 | |
||
Line 46: | Line 46: | ||
| Domain0 | |
| Domain0 | |
||
+--------------------+ |
+--------------------+ |
||
</pre> |
|||
There is a loop in xenbr0 and vmbr0: |
There is a loop in xenbr0 and vmbr0: |
||
<pre |
<pre> |
||
+----------------------------------------------+ |
+----------------------------------------------+ |
||
| switch0 | |
| switch0 | |
||
Line 78: | Line 78: | ||
| Domain0 | | Domain1 | |
| Domain0 | | Domain1 | |
||
+-----------+ +-----------------+ |
+-----------+ +-----------------+ |
||
</pre> |
|||
Line 96: | Line 96: | ||
[[Category:Xen]] |
[[Category:Xen]] |
||
[[Category:Design Document]] |
[[Category:Design Document]] |
||
[ |
[[Category:Developers]] |
Latest revision as of 23:59, 2 June 2014
This article describes the causing of bridge loops in dom0 and domU.
Bridged Network under Xen Overview
Xen uses bridged network by default. For detail, see: Xen Networking.
Why STP is turned off?
It will take longer for the bridge to "settle" when new vifs came online if STP is enabled. When DHCP is enabled, it may cause DHCP requests to time out.
On the other hand, turning off STP along with other parameters (hello/learning latencies) is part of a blanket effort to make the bridge dumb but efficient.
What's the problem?
This simple topology is not hiding bridges. If you intentionally set up soft bridges in the vm, loops may be established. Look at the following two scenarios:
There is a loop in switch0 and xenbr0:
+-----------------------------------+ | switch0 | +-----+--------+----------+-----+---+ | | | | +-----+--------+-----+ PC2 PC3 | | | | | +---+--------+---+ | | | | | | | | | peth0 peth1 | | | | | | | | xenbr0 | | | | | | | | vif0.0 vif0.1 | | | | | | | | | +---+--------+---+ | | | | | | eth0 eth1 | | | | Domain0 | +--------------------+
There is a loop in xenbr0 and vmbr0:
+----------------------------------------------+ | switch0 | +-----+------------------------------+-----+---+ | | | +-----+-------------------------+ PC2 PC3 | | | | +---+-----------------------+ | | | | | | | | peth0 xenbr0 | | | | | | | | vif0.0 vif1.0 vif1.1 | | | | | | | | | | +---+------------+------+---+ | | | | | | | | +------+------+-----+ | | | | | | | | +----+------+-----+ | | | | | | | | | | | +--+------+---+ | | | | | | | | | | | eth0 | | | eth0 eth1 | | | | | | | | | | | | vmbr0 | | | | | +-------------+ | | Domain0 | | Domain1 | +-----------+ +-----------------+
Both of them will cause the switch0 not working. Thus affect all PCs connected to switch0.
The solution is to enable STP on all switch and bridges. Note: only enable STP in one or two bridges is not enough.