Last change
on this file since 129 was
129,
checked in by jazz, 15 years ago
|
- dos2unix/unix2dos cause problem
|
-
Property svn:executable set to
*
|
File size:
971 bytes
|
Rev | Line | |
---|
[129] | 1 | #!/bin/bash |
---|
| 2 | mkdir -p /lib/jvm |
---|
| 3 | mkdir -p /opt |
---|
| 4 | if [ ! -x /lib/jvm/jdk* ]; then |
---|
| 5 | unzip /usr/src/jdk*.zip -d /lib/jvm/ |
---|
| 6 | fi |
---|
| 7 | if [ ! -x /opt/hadoop ]; then |
---|
| 8 | tar zxvf /usr/src/hadoop-*.tar.gz -C /opt/ |
---|
| 9 | ln -s /opt/hadoop-* /opt/hadoop |
---|
| 10 | fi |
---|
| 11 | cp -R /usr/src/conf-examples/ /opt/hadoop/ |
---|
| 12 | mv /opt/hadoop/conf/ /opt/hadoop/conf-org |
---|
| 13 | ln -s /opt/hadoop/conf-examples/ /opt/hadoop/conf |
---|
| 14 | export JAVA_HOME=$(dirname /lib/jvm/jdk*/bin/) |
---|
| 15 | echo JAVA_HOME=$JAVA_HOME >> /opt/hadoop/conf/hadoop-env.sh |
---|
| 16 | ln -s $JAVA_HOME/bin/javac /bin/ |
---|
| 17 | cd $JAVA_HOME |
---|
| 18 | chmod a+x `find . -name "*.exe"` |
---|
| 19 | chmod a+x `find . -name "*.dll"` |
---|
| 20 | javac -version |
---|
| 21 | cd /opt/hadoop |
---|
| 22 | bin/hadoop namenode -format |
---|
| 23 | echo "Press any key to start HDFS and MapReduce Scheduler ..." |
---|
| 24 | read |
---|
| 25 | /opt/hadoop/bin/hadoop-daemon.sh start namenode |
---|
| 26 | /opt/hadoop/bin/hadoop-daemon.sh start datanode |
---|
| 27 | /opt/hadoop/bin/hadoop-daemon.sh start jobtracker |
---|
| 28 | /opt/hadoop/bin/hadoop-daemon.sh start tasktracker |
---|
| 29 | cygstart http://localhost:50070 |
---|
[128] | 30 | cygstart http://localhost:50030 |
---|
Note: See
TracBrowser
for help on using the repository browser.