xenserver: Make vif script log its changes to vswitchd.conf.
authorBen Pfaff <blp@nicira.com>
Thu, 21 May 2009 18:11:08 +0000 (11:11 -0700)
committerBen Pfaff <blp@nicira.com>
Thu, 21 May 2009 18:11:08 +0000 (11:11 -0700)
This makes debugging easier.

xenserver/etc_xensource_scripts_vif

index 3a8d264aa650f50635035aacde01e30fbe4a8c24..01039a34e8bf9dba5f3bbbf977ab1976b3256c6a 100755 (executable)
@@ -90,7 +90,7 @@ add_to_bridge()
         --del-match="bridge.*.port=$vif" \
         --del-match="vlan.$vif.[!0-9]*" \
         --add="bridge.$bridge.port=$vif" \
-        $vid
+        $vid -c
     $service vswitch reload
 
     ${IP} link set "${vif}" up                          || logger -t scripts-vif "Failed to ip link set ${vif} up"
@@ -123,6 +123,6 @@ remove)
        logger -t scripts-vif "${vif} has been removed"
         $cfg_mod -vANY:console:emer -F /etc/vswitchd.conf \
             --del-match="bridge.*.port=${vif}" \
-           --del-match="vlan.${vif}.[!0-9]*"
+           --del-match="vlan.${vif}.[!0-9]*" -c
        ;;
 esac