提交 3a77b671 编写于 作者: D Daniel Gustafsson

Allow gpdemo to be created without checksums

Passing -K to demo_cluster.sh will create gpdemo without enabling
data checksums, which otherwise is the default. The reason for why
one would want to disable checksums is to facilitate testing of
upgrades from a non-checksum cluster to one with (and vice versa).
上级 71916050
#!/bin/bash
# ======================================================================
# Configuration Variables
# ======================================================================
# Set to zero to force cluster to be created without data checksums
DATACHECKSUMS=1
# ======================================================================
# Data Directories
# ======================================================================
......@@ -68,9 +75,10 @@ checkDemoConfig(){
USAGE(){
echo ""
echo " `basename $0` -c -d -u"
echo " -c : check if demo is possible."
echo " `basename $0` {-c | -d | -u} <-K>"
echo " -c : Check if demo is possible."
echo " -d : Delete the demo."
echo " -K : Create cluster without data checksums."
echo " -u : Usage, prints this message."
echo ""
}
......@@ -118,7 +126,7 @@ cleanDemo(){
# Main Section
#*****************************************************************************
while getopts ":cd'?'" opt
while getopts ":cdK'?'" opt
do
case $opt in
'?' ) USAGE ;;
......@@ -133,6 +141,9 @@ do
d) cleanDemo
exit 0
;;
K) DATACHECKSUMS=0
shift
;;
*) USAGE
exit 0
;;
......@@ -278,6 +289,13 @@ cat >> $CLUSTER_CONFIG <<-EOF
ENCODING=UNICODE
EOF
if [ "${DATACHECKSUMS}" == "0" ]; then
cat >> $CLUSTER_CONFIG <<-EOF
# Turn off data checksums
HEAP_CHECKSUM=off
EOF
fi
if [ "${WITH_MIRRORS}" == "true" ]; then
cat >> $CLUSTER_CONFIG <<-EOF
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册