<commit_before>#!/bin/bash
service postgresql start
service ssh start
sleep 10
ambari-server start
ambari-agent start
sleep 10

/usr/jdk64/jdk1.8.0_112/bin/java -jar /tmp/ambari-shell.jar --ambari.host=sandbox << EOF
blueprint add --file /tmp/single-node-hdfs-yarn
cluster build --blueprint single-node-hdfs-yarn
cluster autoAssign
cluster create --exitOnFinish true
EOF

clear

lines=1
while [ $lines -gt 0 ]
do
        sleep 5
        lines=`echo tasks | /usr/jdk64/jdk1.8.0_112/bin/java -jar /tmp/ambari-shell.jar --ambari.host=sandbox | egrep '(PENDING)|(QUEUED)|(IN_PROGRESS)' | wc -l`
        echo $lines
done
amount_started=`echo 'services list' | /usr/jdk64/jdk1.8.0_112/bin/java -jar /tmp/ambari-shell.jar --ambari.host=sandbox | egrep -A 1000 'SERVICE\s+STATE' | tail -n +3 | head -n -2 | awk '{print $2}' | grep -v STARTED | wc -l`
if [ $amount_started -eq 0 ]; then
        echo "done"
        exit 0
else
        echo "there was a problem :("
        exit 1
fi

ambari-agent stop
sleep 10
ambari-server stop
sleep 10<commit_msg>changes in the install script<commit_after>#!/bin/bash
service postgresql start
service ssh start
sleep 10
ambari-server start
ambari-agent start
sleep 10

/usr/jdk64/jdk1.8.0_112/bin/java -jar /tmp/ambari-shell.jar --ambari.host=sandbox << EOF
blueprint add --file /tmp/single-node-hdfs-yarn
cluster build --blueprint single-node-hdfs-yarn
cluster autoAssign
cluster create --exitOnFinish true
exit
EOF

clear
clear

lines=1
while [ $lines -gt 0 ]
do
        sleep 5
        lines=`echo tasks | /usr/jdk64/jdk1.8.0_112/bin/java -jar /tmp/ambari-shell.jar --ambari.host=sandbox | egrep '(PENDING)|(QUEUED)|(IN_PROGRESS)' | wc -l`
        echo $lines
done

amount_started=`echo 'services list' | /usr/jdk64/jdk1.8.0_112/bin/java -jar /tmp/ambari-shell.jar --ambari.host=sandbox | egrep -A 1000 'SERVICE\s+STATE' | tail -n +3 | head -n -2 | awk '{print $2}' | grep -v STARTED | wc -l`
if [ $amount_started -eq 0 ]; then
        echo "done"

        ambari-agent stop
        sleep 10
        ambari-server stop
        sleep 10

        exit 0
else
        echo "there was a problem :("
        exit 1
fi
{'fraction_non_alphanumeric': 0.12785814279048063, 'fraction_numerical': 0.041997200186654225, 'mean_word_length': 2.8491921005385996, 'pattern_counts': {'":': 0, '<': 7, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '6156161', 'n_tokens_mistral': 869, 'n_tokens_neox': 790, 'n_words': 221}