xenserver: Force reload of config file after VIF deleted
authorJustin Pettit <jpettit@nicira.com>
Tue, 16 Jun 2009 19:57:25 +0000 (12:57 -0700)
committerJustin Pettit <jpettit@nicira.com>
Tue, 16 Jun 2009 19:57:25 +0000 (12:57 -0700)
When a VIF is deleted, the "vif" script modifies "/etc/ovs-vswitchd.conf".
After changes are made to the config file, ovs-vswitchd should be told
to reload it, but this wasn't happening.  Now it does.

Thanks to Natasha for catching this.

xenserver/etc_xensource_scripts_vif

index 35ada1f..aebb4cc 100755 (executable)
@@ -128,9 +128,10 @@ remove)
        xenstore-rm "${HOTPLUG}/hotplug"
        vif=vif${DOMID}.${DEVID}
        logger -t scripts-vif "${vif} has been removed"
-        $cfg_mod -vANY:console:emer -F /etc/ovs-vswitchd.conf \
-            --del-match="bridge.*.port=${vif}" \
+       $cfg_mod -vANY:console:emer -F /etc/ovs-vswitchd.conf \
+           --del-match="bridge.*.port=${vif}" \
            --del-match="vlan.${vif}.[!0-9]*" \
            --del-match="port.${vif}.[!0-9]*" -c
+       $service vswitch reload
        ;;
 esac