Output redirection errors fixed
@@ -209,7 +209,7 @@ if [ $ERROR -ne 0 ]; then
fi
echo "Installing logstash"
-apt-get install -y logstash=1:$ELKVERSION-1 > $LOGFILE 2>&1
+apt-get install -y logstash=1:$ELKVERSION-1 >> $LOGFILE 2>&1
ERROR=$?
if [ $ERROR -ne 0 ]; then
echoerror "Could not install logstash (Error Code: $ERROR)."
@@ -259,7 +259,7 @@ fi
cd $CWD
echo "Installing elasticsearch"
-apt-get install -y elasticsearch=$ELKVERSION > $LOGFILE 2>&1
+apt-get install -y elasticsearch=$ELKVERSION >> $LOGFILE 2>&1
ERROR=$?
if [ $ERROR -ne 0 ]; then
echoerror "Could not install elasticsearch (Error Code: $ERROR)."
@@ -273,14 +273,14 @@ if [ $ERROR -ne 0 ]; then
fi
echo "Adjusting memory settings for ES"
-sed -E -i.bak "s/Xms1g/Xms${ES_MEMORY}/g" /etc/elasticsearch/jvm.options && sed -E -i.bak2 "s/Xmx1g/Xmx${ES_MEMORY}/g" /etc/elasticsearch/jvm.options && sed -E -i.bak "s/#bootstrap.memory_lock: true/bootstrap.memory_lock: true/g" /etc/elasticsearch/elasticsearch.yml > $LOGFILE 2>&1
+sed -E -i.bak "s/Xms1g/Xms${ES_MEMORY}/g" /etc/elasticsearch/jvm.options && sed -E -i.bak2 "s/Xmx1g/Xmx${ES_MEMORY}/g" /etc/elasticsearch/jvm.options && sed -E -i.bak "s/#bootstrap.memory_lock: true/bootstrap.memory_lock: true/g" /etc/elasticsearch/elasticsearch.yml >> $LOGFILE 2>&1
ERROR=$?
if [ $ERROR -ne 0 ]; then
echoerror "Coul not adjust ES memory settings (Error Code: $ERROR)."
fi
echo "Installing Kibana"
-apt-get install -y kibana=$ELKVERSION > $LOGFILE 2>&1
+apt-get install -y kibana=$ELKVERSION >> $LOGFILE 2>&1
ERROR=$?
if [ $ERROR -ne 0 ]; then
echoerror "Could not install Kibana (Error Code: $ERROR)."
@@ -294,7 +294,7 @@ if [ $ERROR -ne 0 ]; then
fi
echo "Installing nginx"
-apt-get install -y nginx > $LOGFILE 2>&1
+apt-get install -y nginx >> $LOGFILE 2>&1
ERROR=$?
if [ $ERROR -ne 0 ]; then
echoerror "Could not install nginx (Error Code: $ERROR)."
