From fce20b8b73b1c08bc0f51a04a2109d80e4bc8b51 Mon Sep 17 00:00:00 2001 From: Timothy Redaelli Date: Mon, 11 Feb 2019 19:55:52 +0100 Subject: [PATCH] ovs-ctl: Permit to specify additional options Currently using ovs-ctl is not possible to specify additional options for ovs-vswitchd and ovsdb-server (for example to specify a different loglevel during daemon startup). This patch adds --ovs-vswitchd-options and --ovsdb-server-options options to ovs-ctl in order to specify the additional options. Due to word splitting it may not be possible to specify an option that includes whitespaces. Reported-at: https://bugzilla.redhat.com/1664794 Reported-by: Matt Flusche Signed-off-by: Timothy Redaelli Signed-off-by: Ben Pfaff --- utilities/ovs-ctl.in | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/utilities/ovs-ctl.in b/utilities/ovs-ctl.in index 9c2a092ea..8c5cd7032 100644 --- a/utilities/ovs-ctl.in +++ b/utilities/ovs-ctl.in @@ -144,6 +144,7 @@ do_start_ovsdb () { set "$@" --certificate=db:Open_vSwitch,SSL,certificate set "$@" --bootstrap-ca-cert=db:Open_vSwitch,SSL,ca_cert [ "$OVS_USER" != "" ] && set "$@" --user "$OVS_USER" + [ "$OVSDB_SERVER_OPTIONS" != "" ] && set "$@" $OVSDB_SERVER_OPTIONS start_daemon "$OVSDB_SERVER_PRIORITY" "$OVSDB_SERVER_WRAPPER" "$@" \ || return 1 @@ -213,6 +214,7 @@ do_start_forwarding () { set "$@" --no-self-confinement fi [ "$OVS_USER" != "" ] && set "$@" --user "$OVS_USER" + [ "$OVS_VSWITCHD_OPTIONS" != "" ] &&set "$@" $OVS_VSWITCHD_OPTIONS start_daemon "$OVS_VSWITCHD_PRIORITY" "$OVS_VSWITCHD_WRAPPER" "$@" || return 1 @@ -326,6 +328,8 @@ set_defaults () { OVS_VSWITCHD_PRIORITY=-10 OVSDB_SERVER_WRAPPER= OVS_VSWITCHD_WRAPPER= + OVSDB_SERVER_OPTIONS= + OVS_VSWITCHD_OPTIONS= DB_FILE=$dbdir/conf.db DB_SOCK=$rundir/db.sock