git.samba.org
/
vlendec
/
samba-autobuild
/
.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
ba6612e
)
ctdb_check_tcp_ports: fail the check if neither netstat nor netcat/nc is found
author
Michael Adam
<obnox@samba.org>
Fri, 30 Jan 2009 15:41:37 +0000
(16:41 +0100)
committer
Michael Adam
<obnox@samba.org>
Fri, 30 Jan 2009 21:45:52 +0000
(22:45 +0100)
Michael
(This used to be ctdb commit
25d04bbe9528fafc68751f7beb22daeee3163d34
)
ctdb/config/functions
patch
|
blob
|
history
diff --git
a/ctdb/config/functions
b/ctdb/config/functions
index ea5f5a07f4389a428cc722086ed79d17a81a975d..826febf15867ebe689637c16ff2ff12c14a322e8 100644
(file)
--- a/
ctdb/config/functions
+++ b/
ctdb/config/functions
@@
-230,6
+230,10
@@
ctdb_check_tcp_ports() {
${NETCAT} -z 127.0.0.1 $p > /dev/null || all_ok=0
elif [ "x${NETSTAT}" != "x" ]; then
( ${NETSTAT} -a -n | egrep "0.0.0.0:$p .*LISTEN" > /dev/null ) || all_ok=0
+ else
+ echo "ERROR: neither netcat (or nc) nor netstat found!"
+ echo "ERROR: can't monitor ${service_name} tcp port ${p}"
+ all_ok=0
fi
[ $all_ok -eq 1 ] || {