From dabd5d6e34d6b39eb1312a58e4b6ce43329e01c2 Mon Sep 17 00:00:00 2001 From: Sage Weil Date: Fri, 13 Dec 2013 14:50:34 -0800 Subject: [PATCH] vstart.sh: --hitset Signed-off-by: Sage Weil --- src/vstart.sh | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) diff --git a/src/vstart.sh b/src/vstart.sh index 4839cc1156d..86f969a76d6 100755 --- a/src/vstart.sh +++ b/src/vstart.sh @@ -34,6 +34,7 @@ start_rgw=0 ip="" nodaemon=0 smallmds=0 +hitset="" overwrite_conf=1 cephx=1 #turn cephx on by default @@ -60,6 +61,7 @@ usage=$usage"\t-m ip:port\t\tspecify monitor address\n" usage=$usage"\t-k keep old configuration files\n" usage=$usage"\t-x enable cephx (on by default)\n" usage=$usage"\t-X disable cephx\n" +usage=$usage"\t--hitset : enable hitset tracking\n" usage=$usage"\t-o config\t\t add extra config parameters to mds section\n" usage_exit() { @@ -141,6 +143,11 @@ case $1 in -k ) overwrite_conf=0 ;; + --hitset ) + hitset="$hitset $2 $3" + shift + shift + ;; -o ) extra_conf="$extra_conf $2 " @@ -571,6 +578,20 @@ EOF done fi +do_hitsets() { + while [ -n "$*" ]; do + pool="$1" + type="$2" + shift + shift + echo "setting hit_set on pool $pool type $type ..." + $CEPH_ADM osd pool set $pool hit_set_type $type + $CEPH_ADM osd pool set $pool hit_set_count 8 + $CEPH_ADM osd pool set $pool hit_set_period 30 + done +} +do_hitsets $hitset + echo "started. stop.sh to stop. see out/* (e.g. 'tail -f out/????') for debug output." echo "" -- 2.47.3