2017年3月1日, 星期三
附录:
不同运行模式的命令不同
1.standalone client模式
./bin/spark-submit --class org.apache.spark.examples.SparkPi--master spark://master:7077 --executor-memory 512m --total-executor-cores 1 ./lib/spark-examples-1.6.0-hadoop2.6.0.jar 100
2.standalone cluster模式
./bin/spark-submit --class org.apache.spark.examples.SparkPi--master spark://spark001:7077 --driver-memory 512m --deploy-mode cluster --supervise --executor-memory 512M --total-executor-cores 1 ./lib/spark-examples-1.6.0-hadoop2.6.0.jar 100
3.on yarn client模式
./bin/spark-submit --class org.apache.spark.examples.SparkPi--master yarn-client --executor-memory 512M--num-executors 1./lib/spark-examples-1.6.0-hadoop2.6.0.jar 100
4.on yarn cluster模式
./bin/spark-submit --class org.apache.spark.examples.SparkPi--master yarn-cluster --executor-memory 512m--num-executors 1./lib/spark-examples-1.6.0-hadoop2.6.0.jar 100
原文:http://www.cnblogs.com/haozhengfei/p/900b724dac15dbbe0a914facdca09118.html