diff mbox series

[ovs-dev,02/11] ovs-sandbox: Make it possible to disable recording ddlog input.

Message ID 20210304041012.4128938-3-blp@ovn.org
State Accepted
Headers show
Series ovn-northd-ddlog improvements | expand

Commit Message

Ben Pfaff March 4, 2021, 4:10 a.m. UTC
The recording is useful for debugging and reproducing runs, but it
does cost CPU time, so with this option it can be disabled.

Signed-off-by: Ben Pfaff <blp@ovn.org>
---
 tutorial/ovs-sandbox | 7 ++++++-
 1 file changed, 6 insertions(+), 1 deletion(-)
diff mbox series

Patch

diff --git a/tutorial/ovs-sandbox b/tutorial/ovs-sandbox
index 21bc594467a0..08a3629be7f6 100755
--- a/tutorial/ovs-sandbox
+++ b/tutorial/ovs-sandbox
@@ -73,6 +73,7 @@  installed=false
 built=false
 ovn=true
 ddlog=false
+ddlog_record=true
 ovnsb_schema=
 ovnnb_schema=
 ic_sb_schema=
@@ -145,6 +146,7 @@  General options:
 
 OVN options:
   --ddlog              use ovn-northd-ddlog
+  --no-ddlog-record    do not record ddlog transactions (for performance)
   --no-ovn-rbac        disable role-based access control for OVN
   --n-northds=NUMBER   run NUMBER copies of northd (default: 1)
   --n-ics=NUMBER       run NUMBER copies of ic (default: 1)
@@ -239,6 +241,9 @@  EOF
         --ddlog)
             ddlog=true
             ;;
+        --no-ddlog-record | --no-record-ddlog)
+            ddlog_record=false
+            ;;
         --no-ovn-rbac)
             ovn_rbac=false
             ;;
@@ -624,7 +629,7 @@  fi
 
 for i in $(seq $n_northds); do
     if [ $i -eq 1 ]; then inst=""; else inst=$i; fi
-    if $ddlog; then
+    if $ddlog && $ddlog_record; then
         northd_args=--ddlog-record=replay$inst.txt
     fi
     rungdb $gdb_ovn_northd $gdb_ovn_northd_ex $OVN_NORTHD --detach \