diff options
author | Denny <dennybritz@gmail.com> | 2012-08-01 13:17:31 -0700 |
---|---|---|
committer | Denny <dennybritz@gmail.com> | 2012-08-01 20:38:52 -0700 |
commit | 0ee44c225e38abbf3382be6e9555ab9a35424a54 (patch) | |
tree | 9fc106518bf55fc27083463843e9ee591c63ee59 /bin/spark-daemons.sh | |
parent | 545165e8153bb516d4364f9b3df1440c6b44c01b (diff) | |
download | spark-0ee44c225e38abbf3382be6e9555ab9a35424a54.tar.gz spark-0ee44c225e38abbf3382be6e9555ab9a35424a54.tar.bz2 spark-0ee44c225e38abbf3382be6e9555ab9a35424a54.zip |
Spark standalone mode cluster scripts.
Heavily inspired by Hadoop cluster scripts ;-)
Diffstat (limited to 'bin/spark-daemons.sh')
-rwxr-xr-x | bin/spark-daemons.sh | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/bin/spark-daemons.sh b/bin/spark-daemons.sh new file mode 100755 index 0000000000..4f9719ee80 --- /dev/null +++ b/bin/spark-daemons.sh @@ -0,0 +1,18 @@ +#!/usr/bin/env bash + +# Run a Spark command on all slave hosts. + +usage="Usage: spark-daemons.sh [--config confdir] [--hosts hostlistfile] [start|stop] command args..." + +# if no args specified, show usage +if [ $# -le 1 ]; then + echo $usage + exit 1 +fi + +bin=`dirname "$0"` +bin=`cd "$bin"; pwd` + +. "$bin/spark-config.sh" + +exec "$bin/slaves.sh" cd "$SPARK_HOME" \; "$bin/spark-daemon.sh" "$@" |