diff options
author | kalpit <shahkalpit84@gmail.com> | 2013-03-06 18:06:32 -0800 |
---|---|---|
committer | kalpit <shahkalpit84@gmail.com> | 2013-03-26 17:49:30 -0700 |
commit | f08db010d3ba4eff132f5c06a087b0c7c2e58576 (patch) | |
tree | 6b08dfbbcb05594b7ce2d712d33e105bf9bd214c /bin/spark-daemon.sh | |
parent | f0164e5047f3a023768cdf0515a7a7d1c75ef7c3 (diff) | |
download | spark-f08db010d3ba4eff132f5c06a087b0c7c2e58576.tar.gz spark-f08db010d3ba4eff132f5c06a087b0c7c2e58576.tar.bz2 spark-f08db010d3ba4eff132f5c06a087b0c7c2e58576.zip |
added SPARK_WORKER_INSTANCES : allows spawning multiple worker instances/processes on every slave machine
Diffstat (limited to 'bin/spark-daemon.sh')
-rwxr-xr-x | bin/spark-daemon.sh | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/bin/spark-daemon.sh b/bin/spark-daemon.sh index 0c584055c7..d7dc62ab08 100755 --- a/bin/spark-daemon.sh +++ b/bin/spark-daemon.sh @@ -30,7 +30,7 @@ # SPARK_NICENESS The scheduling priority for daemons. Defaults to 0. ## -usage="Usage: spark-daemon.sh [--config <conf-dir>] [--hosts hostlistfile] (start|stop) <spark-command> <args...>" +usage="Usage: spark-daemon.sh [--config <conf-dir>] [--hosts hostlistfile] (start|stop) <spark-command> <spark-instance-number> <args...>" # if no args specified, show usage if [ $# -le 1 ]; then @@ -48,6 +48,8 @@ startStop=$1 shift command=$1 shift +instance=$1 +shift spark_rotate_log () { @@ -95,7 +97,7 @@ fi export SPARK_LOGFILE=spark-$SPARK_IDENT_STRING-$command-$HOSTNAME.log export SPARK_ROOT_LOGGER="INFO,DRFA" log=$SPARK_LOG_DIR/spark-$SPARK_IDENT_STRING-$command-$HOSTNAME.out -pid=$SPARK_PID_DIR/spark-$SPARK_IDENT_STRING-$command.pid +pid=$SPARK_PID_DIR/spark-$SPARK_IDENT_STRING-$command-$instance.pid # Set default scheduling priority if [ "$SPARK_NICENESS" = "" ]; then |