summaryrefslogtreecommitdiffstats
path: root/ctdb/config/functions
diff options
context:
space:
mode:
authorMartin Schwenke <martin@meltin.net>2013-04-30 15:33:12 +1000
committerAmitay Isaacs <amitay@gmail.com>2013-05-06 16:24:59 +1000
commit2bc807f9748f406c2fdd55fe187b0dc74014d5e0 (patch)
treedf532162e1ce5767390faf114ebd9336cb8d0008 /ctdb/config/functions
parent460d0651b6316e0f44c338d50a9dffb88778b360 (diff)
downloadsamba-2bc807f9748f406c2fdd55fe187b0dc74014d5e0.tar.gz
samba-2bc807f9748f406c2fdd55fe187b0dc74014d5e0.tar.xz
samba-2bc807f9748f406c2fdd55fe187b0dc74014d5e0.zip
eventscripts: Remove unused function ctdb_check_counter_limit()
Signed-off-by: Martin Schwenke <martin@meltin.net> (This used to be ctdb commit a8ef00608e48a551a334aded206146807aeb4c5a)
Diffstat (limited to 'ctdb/config/functions')
-rwxr-xr-xctdb/config/functions15
1 files changed, 0 insertions, 15 deletions
diff --git a/ctdb/config/functions b/ctdb/config/functions
index 6c5891697c9..3572a008190 100755
--- a/ctdb/config/functions
+++ b/ctdb/config/functions
@@ -953,21 +953,6 @@ ctdb_counter_incr () {
# unary counting!
echo -n 1 >> "$_counter_file"
}
-ctdb_check_counter_limit () {
- _ctdb_counter_common
-
- _limit="${1:-${service_fail_limit}}"
- _quiet="$2"
-
- # unary counting!
- _size=$(stat -c "%s" "$_counter_file" 2>/dev/null || echo 0)
- if [ $_size -ge $_limit ] ; then
- echo "ERROR: more than $_limit consecutive failures for $service_name, marking cluster unhealthy"
- exit 1
- elif [ $_size -gt 0 -a -z "$_quiet" ] ; then
- echo "WARNING: less than $_limit consecutive failures ($_size) for $service_name, not unhealthy yet"
- fi
-}
ctdb_check_counter () {
_msg="${1:-error}" # "error" - anything else is silent on fail
_op="${2:--ge}" # an integer operator supported by test