From: Numan Siddique <nusid...@redhat.com> When '--ovn-manage-ovsdb=no' is passed to "ovn-ctl start_northd", it doesn't start ovsdb-servers, but it expects the ovsdb-servers to be running. If the ovsdb-servers are not running, ovn-ctl exits without starting ovn-northd. This could create problems when ovn-northd and ovsdb-servers are managed separately, for example when pacemaker is used to manage ocf:ovndb-servers and ovn-northd as separate resources. In the cases where a slave is promoted as master, it is possible that pacemaker might start ovn-northd service before starting ovsdb-servers.
This patch addresses this issue by not checking the status of ovsdb-server pids when ovn-manage-ovsdb is set to true when 'start_northd' is called. ovn-northd will eventually connect to the ovsdb-servers when they are started. So there is no harm in removing this check. Signed-off-by: Numan Siddique <nusid...@redhat.com> --- ovn/utilities/ovn-ctl | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/ovn/utilities/ovn-ctl b/ovn/utilities/ovn-ctl index a3bdad1..bff09b6 100755 --- a/ovn/utilities/ovn-ctl +++ b/ovn/utilities/ovn-ctl @@ -188,15 +188,15 @@ start_northd () { if [ ! -e $ovn_northd_db_conf_file ]; then if test X"$OVN_MANAGE_OVSDB" = Xyes; then start_ovsdb - fi - if ! pidfile_is_running $DB_NB_PID; then - log_failure_msg "OVN Northbound DB is not running" - exit - fi - if ! pidfile_is_running $DB_SB_PID; then - log_failure_msg "OVN Southbound DB is not running" - exit + if ! pidfile_is_running $DB_NB_PID; then + log_failure_msg "OVN Northbound DB is not running" + exit + fi + if ! pidfile_is_running $DB_SB_PID; then + log_failure_msg "OVN Southbound DB is not running" + exit + fi fi ovn_northd_params="--ovnnb-db=unix:$DB_NB_SOCK --ovnsb-db=unix:$DB_SB_SOCK" else -- 2.9.3 _______________________________________________ dev mailing list d...@openvswitch.org https://mail.openvswitch.org/mailman/listinfo/ovs-dev