[ovs-dev] [PATCH ovn 05/19] ovn-lib.in: Fix ovn-ctl status_xxx.

Han Zhou hzhou at ovn.org
Mon Oct 21 00:51:05 UTC 2019


Currently ovn-ctl status_xxx (e.g. status_northd) shows "not running" even
when the daemon is running, because it is calling daemon_status() which is
defined in ovs-ctl using OVS rundir instead of OVN rundir.

A new function ovn_daemon_status was introduced to replace daemon_status
as part of ovn/ovs split.  We could fix the problem by replacing all
daemon_status() call to ovn_daemon_status() call.  However, this is not
necessary because when same function name is defined in both ovn-lib
and ovs-lib, the one in ovn-lib will take effect.  So this patch simply
renames the ovn_daemon_status() back to daemon_status().

Signed-off-by: Han Zhou <hzhou at ovn.org>
---
 utilities/ovn-lib.in | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/utilities/ovn-lib.in b/utilities/ovn-lib.in
index a8fc9d6..af1b72e 100644
--- a/utilities/ovn-lib.in
+++ b/utilities/ovn-lib.in
@@ -179,7 +179,7 @@ stop_ovn_daemon () {
     log_success_msg "$1 is not running"
 }
 
-ovn_daemon_status () {
+daemon_status () {
     pidfile=$ovn_rundir/$1.pid
     if test -e "$pidfile"; then
         if pid=`cat "$pidfile"`; then
-- 
2.1.0



More information about the dev mailing list