ia64/xen-unstable

changeset 1761:bfc886b99735

bitkeeper revision 1.1071 (40f32d351AUI5dQyI8HcrYtyF1eppg)

minor reordering to /etc/xen/network seems to make it more robust
when in an NFS mounted directory.
author iap10@labyrinth.cl.cam.ac.uk
date Tue Jul 13 00:30:45 2004 +0000 (2004-07-13)
parents cbf1c89cb69b
children b9fc18608f2b f99dd2296127
files tools/examples/network
line diff
     1.1 --- a/tools/examples/network	Mon Jul 12 22:19:03 2004 +0000
     1.2 +++ b/tools/examples/network	Tue Jul 13 00:30:45 2004 +0000
     1.3 @@ -1,4 +1,4 @@
     1.4 -#!/bin/sh 
     1.5 +#!/bin/sh
     1.6  #============================================================================
     1.7  # Example Xen network start/stop script.
     1.8  # Xend calls a network script when it starts.
     1.9 @@ -99,10 +99,6 @@ create_bridge () {
    1.10          brctl sethello ${bridge} 0
    1.11      fi
    1.12      ifconfig ${bridge} up
    1.13 -    # Don't add $dev to $bridge if it's already on a bridge.
    1.14 -    if ! brctl show | grep -q ${dev} ; then
    1.15 -        brctl addif ${bridge} ${dev}
    1.16 -    fi
    1.17  }
    1.18  
    1.19  # Usage: antispoofing dev bridge
    1.20 @@ -139,6 +135,10 @@ case ${OP} in
    1.21          create_bridge ${netdev} ${bridge}
    1.22          transfer_addrs ${netdev} ${bridge}
    1.23          transfer_routes ${netdev} ${bridge}
    1.24 +	# Don't add $dev to $bridge if it's already on a bridge.
    1.25 +	if ! brctl show | grep -q ${netdev} ; then
    1.26 +	    brctl addif ${bridge} ${netdev}
    1.27 +	fi
    1.28          
    1.29          if [ ${antispoof} == 'yes' ] ; then
    1.30              antispoofing ${netdev} ${bridge}