xentaur
diff xentaur.py @ 24:fcd08a4f3216
reconnect and show
author | igor |
---|---|
date | Fri Sep 21 16:19:12 2007 +0300 (2007-09-21) |
parents | 6bb2a29e91be |
children | a268a7754150 |
line diff
1.1 --- a/xentaur.py Fri Sep 21 16:01:04 2007 +0300 1.2 +++ b/xentaur.py Fri Sep 21 16:19:12 2007 +0300 1.3 @@ -227,7 +227,7 @@ 1.4 def int_connect(domain, int_number, bridge): 1.5 """ 1.6 Connect the interface with the number <int_number> 1.7 - of the domain <domain> the the bridge <bridge> 1.8 + of the domain <domain> to the bridge <bridge> 1.9 """ 1.10 dom_id=get_domain_id(domain) 1.11 1.12 @@ -237,6 +237,18 @@ 1.13 run_command("sudo brctl addif %s vif%s.%s" % (bridge, dom_id, int_number)) 1.14 vbridges_table[domain][int_number]=bridge 1.15 1.16 +def int_reconnect(domain, int_number, bridge): 1.17 + """ 1.18 + Reconnect the interface with the number <int_number> 1.19 + of the domain <domain> from the bridge to which 1.20 + it is connected to the bridge <bridge> 1.21 + """ 1.22 + int_disconnect(domain, int_number) 1.23 + int_connect(domain, int_number, bridge) 1.24 + 1.25 +def show_int(domain, int_number): 1.26 + vbridges_table[domain][int_number] 1.27 + 1.28 #----------------------------------------------------------------------- 1.29 1.30