util: New functions get_cwd(), abs_file_name().
[openvswitch] / xenserver / etc_init.d_vswitch
index 480f9a9c42f84d8b1dda96e3d2f6a5707e380707..304eabb1cf962b5fd0da18aee5eedeae5dd0aa23 100755 (executable)
@@ -318,6 +318,16 @@ EOF
     esac
 }
 
+function set_system_uuid {
+    system_uuid=$(. /etc/xensource-inventory && echo $INSTALLATION_UUID)
+    if test -n "$system_uuid"; then
+        action "Configuring Open vSwitch system UUID" true
+        $vsctl --no-wait set Open_vSwitch . external-ids:system-uuid="$system_uuid"
+    else
+        action "Configuring Open vSwitch system UUID" false
+    fi
+}
+
 function start {
     if [ "$FORCE_COREFILES" = "y" ]; then
         turn_on_corefiles
@@ -351,6 +361,8 @@ function start {
         done
     fi
 
+    set_system_uuid
+
     start_vswitchd
     start_brcompatd
     touch /var/lock/subsys/vswitch