From 50c8c6eb441f47f1e285c9f2872be9957bf256dd Mon Sep 17 00:00:00 2001 From: Ben Pfaff Date: Thu, 21 May 2009 13:25:40 -0700 Subject: [PATCH] xenserver: Remove bridge configuration files when they become stale. interface-reconfigure communicates with the vif script using files in /etc/openvswitch, but it didn't delete them when they were stale. This commit fixes the problem. --- xenserver/opt_xensource_libexec_interface-reconfigure | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/xenserver/opt_xensource_libexec_interface-reconfigure b/xenserver/opt_xensource_libexec_interface-reconfigure index 3b99820f..3de1099d 100755 --- a/xenserver/opt_xensource_libexec_interface-reconfigure +++ b/xenserver/opt_xensource_libexec_interface-reconfigure @@ -842,6 +842,11 @@ def action_up(pif): f.close() f.apply() f.commit() + else: + try: + os.unlink("%s/br-%s" % (vswitch_config_dir, bridge)) + except OSError: + pass if bond_master: argv += configure_bond(bond_master) modify_config(argv) -- 2.30.2