-
Notifications
You must be signed in to change notification settings - Fork 15
/
Copy pathstart.sh
40 lines (29 loc) · 925 Bytes
/
start.sh
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
#!/bin/bash
echo " "
echo -e "\e[00;37m*\e[00m `date` \e[00;37mStarting Supervidord\e[00m"
nohup /usr/bin/supervisord -c /etc/supervisord.conf &
sleep 3
#/etc/init.d/ssh start
echo " "
echo -e "\e[01;37m*\e[00m `date` \e[01;37mStarting HDFS - NameNode DataNodes\e[00m"
start-dfs.sh
echo " "
echo -e "\e[01;37m*\e[00m `date` \e[01;37mStarting YARN - Resource Manager\e[00m"
start-yarn.sh
$HADOOP_HOME/sbin/mr-jobhistory-daemon.sh start historyserver
if [[ $1 == "bash" ]]; then
echo " "
echo -e "\e[01;32m*\e[00m `date` \e[01;32mShell Bash\e[00m"
/bin/bash
fi
if [[ $1 == "-test" ]]; then
echo " "
echo -e "\e[00;33m*\e[00m `date` \e[00;33mtesting Hadoop MapReduce ..\e[00m"
hadoop jar $HADOOP_HOME/share/hadoop/mapreduce/hadoop-mapreduce-examples-2.8.5.jar pi 16 1000
fi
if [[ $2 == "bash" ]]; then
echo " "
echo -e "\e[01;32m*\e[00m `date` \e[01;32mShell Bash\e[00m"
/bin/bash
fi
sleep 31557600