Permalink
Browse files

ACCUMULO-1071 stopped automatically populating conf dir in bin/config.sh

git-svn-id: https://svn.apache.org/repos/asf/accumulo/trunk@1459090 13f79535-47bb-0310-9956-ffa450edef68
  • Loading branch information...
2 parents b9f030c + 298a1f0 commit f765878d4c4e6a4d79c8bc68e84c3326102b76dc @keith-turner keith-turner committed Mar 20, 2013
Showing with 9 additions and 29 deletions.
  1. +5 −0 bin/bootstrap_config.sh
  2. +4 −29 bin/config.sh
View
@@ -41,6 +41,11 @@ if [ "$2" = "native" ]; then
TYPE="native-standalone"
fi
+if [ -z "${SIZE}" -a -z "${TYPE}" ]; then
+ echo "Please choose from the following example configurations..."
+ echo ""
+fi
+
if [ -z "${SIZE}" ]; then
echo "Choose the heap configuration:"
select DIRNAME in $(cd ${ACCUMULO_HOME}/conf/examples && ls -d */standalone/.. | sed -e 's/\/.*//'); do
View
@@ -37,11 +37,11 @@ else
#
echo ""
echo "Accumulo is not properly configured."
- echo "Please choose from the following example configurations..."
echo ""
- $ACCUMULO_HOME/bin/bootstrap_config.sh
- [[ $? != 0 ]] && echo "Bootstrap canceled, exiting..." && exit 1
- . $ACCUMULO_HOME/conf/accumulo-env.sh
+ echo "Try running \$ACCUMULO_HOME/bin/bootstrap_config.sh and then editing"
+ echo "\$ACCUMULO_HOME/conf/accumulo-env.sh"
+ echo ""
+ exit 1
fi
if [ -z ${ACCUMULO_LOG_DIR} ]; then
@@ -74,31 +74,6 @@ then
fi
export HADOOP_PREFIX
-if [ ! -f "$ACCUMULO_HOME/conf/masters" -o ! -f "$ACCUMULO_HOME/conf/slaves" ]; then
- if [ ! -f "$ACCUMULO_HOME/conf/masters" -a ! -f "$ACCUMULO_HOME/conf/slaves" ]; then
- echo "STANDALONE: Missing both conf/masters and conf/slaves files"
- echo "STANDALONE: Assuming single-node (localhost only) instance"
- echo "STANDALONE: echo "`hostname`" > $ACCUMULO_HOME/conf/masters"
- echo `hostname` > "$ACCUMULO_HOME/conf/masters"
- echo "STANDALONE: echo "`hostname`" > $ACCUMULO_HOME/conf/slaves"
- echo `hostname` > "$ACCUMULO_HOME/conf/slaves"
- fgrep -s logger.dir.walog "$ACCUMULO_HOME/conf/accumulo-site.xml" > /dev/null
- WALOG_CONFIGURED=$?
- if [ $WALOG_CONFIGURED -ne 0 -a ! -e "$ACCUMULO_HOME/walogs" ]; then
- echo "STANDALONE: Creating default local write-ahead log directory"
- mkdir "$ACCUMULO_HOME/walogs"
- echo "STANDALONE: mkdir \"$ACCUMULO_HOME/walogs\""
- fi
- if [ ! -e "$ACCUMULO_HOME/conf/accumulo-metrics.xml" ]; then
- echo "STANDALONE: Creating default metrics configuration"
- cp "$ACCUMULO_HOME/conf/accumulo-metrics.xml.example" "$ACCUMULO_HOME/conf/accumulo-metrics.xml"
- fi
- else
- echo "You are missing either $ACCUMULO_HOME/conf/masters or $ACCUMULO_HOME/conf/slaves"
- echo "Please configure them both for a multi-node instance, or delete them both for a single-node (localhost only) instance"
- exit 1
- fi
-fi
MASTER1=$(egrep -v '(^#|^\s*$)' "$ACCUMULO_HOME/conf/masters" | head -1)
GC=$MASTER1
MONITOR=$MASTER1

0 comments on commit f765878

Please sign in to comment.