[ovs-dev] [PATCH]: ovs-ctl: let openvswitch startup to NOT hold up system boot upon error

Sabyasachi Sengupta Sabyasachi.Sengupta at alcatel-lucent.com
Thu Jun 11 23:07:00 UTC 2015


Abort openvswitch startup script if ovsdb startup fails for
some reason. This helps in getting the system startup to NOT hang
indefinitely, as was seen in a recent report when ovsdb failed with
"I/O error: /etc/openvswitch/conf.db: failed to lock lockfile
(Resource temporarily unavailable)" and system remained in hung state
forever, unless manually rebooted from console.

Signed-off-by: Sabyasachi Sengupta <sabyasachi.sengupta at alcatel-lucent.com>

---
diff --git a/utilities/ovs-ctl.in b/utilities/ovs-ctl.in
index 97716e9..449e715 100755
--- a/utilities/ovs-ctl.in
+++ b/utilities/ovs-ctl.in
@@ -718,6 +718,9 @@ done
  case $command in
      start)
          start_ovsdb
+        if [ $? -ne 0 ]; then
+            exit 1
+        fi
          start_forwarding
          add_managers
          ;;
---



More information about the dev mailing list