summaryrefslogtreecommitdiffstats
path: root/tests/afr.rc
diff options
context:
space:
mode:
Diffstat (limited to 'tests/afr.rc')
-rw-r--r--tests/afr.rc16
1 files changed, 16 insertions, 0 deletions
diff --git a/tests/afr.rc b/tests/afr.rc
index 35f352d..2417899 100644
--- a/tests/afr.rc
+++ b/tests/afr.rc
@@ -105,3 +105,19 @@ function get_quorum_type()
local repl_id="$3"
cat $m/.meta/graphs/active/$v-replicate-$repl_id/private|grep quorum-type|awk '{print $3}'
}
+
+function afr_private_key_value()
+{
+ local v=$1
+ local m=$2
+ local replica_id=$3
+ local key=$4
+#xargs at the end will strip leading spaces
+ grep -E "^${key} = " $m/.meta/graphs/active/${v}-replicate-${replica_id}/private | cut -f2 -d'=' | xargs
+}
+
+function afr_anon_entry_count()
+{
+ local b=$1
+ ls $b/.glusterfs-anonymous-inode* | wc -l
+}