#!/bin/bash
if [ X$1 == X ] || [ X$2 == X ] || [ X$3 == X ] || [ X$4 == X ] || [ X$5 == X ]; then
echo "usage: $0 <threads> <target> <workload> <ispn_url> <operationcount>"
exit 1
fi
hyperentoli="java -XmsMINMEMm -XmxMAXMEMm -XX:MaxPermSize=MAXMEMm -cp /opt/YCSB/build/ycsb.jar:/opt/YCSB/db/infinispan/lib/*:/opt/YCSB/lib/* com.yahoo.ycsb.Client -db com.yahoo.ycsb.db.InfinispanClient -s"
if [ $1 != "0" ]; then
hyperentoli=$hyperentoli" -threads $1"
fi
if [ $2 != "0" ]; then
hyperentoli=$hyperentoli" -target $2"
fi
if [ $3 != "0" ]; then
hyperentoli=$hyperentoli" -P /opt/YCSB/workloads/$3"
else
hyperentoli=$hyperentoli" -P /opt/YCSB/workloads/workloadread"
fi
if [ $4 != "0" ]; then
hyperentoli=$hyperentoli" -p ispn_url=$4"
fi
if [ $5 != "0" ]; then
hyperentoli=$hyperentoli" -p operationcount=$5"
else
hyperentoli=$hyperentoli" -p operationcount=1000000"
fi
if [ $6 != "0" ]; then
hyperentoli=$hyperentoli" -p gangserver=$6"
else
hyperentoli=$hyperentoli" -p gangserver=hbase-nodes-master:hbase-nodes-master"
fi
if [ $7 != "0" ]; then
hyperentoli=$hyperentoli" -masterIP $7"
else
hyperentoli=$hyperentoli" -masterIP 192.168.1.74"
fi
if [ $8 != "0" ]; then
hyperentoli=$hyperentoli" -p clientno=$8"
else
hyperentoli=$hyperentoli" -p clientno=0"
fi
date
echo $hyperentoli
$hyperentoli
date