Spark2.X集群运行模式

时间:2021-11-26 02:03:49

rn

启动Spark2.X集群运行模式

Spark2.X集群运行模式

Spark2.X集群运行模式

Spark2.X集群运行模式

Spark2.X集群运行模式

先把这三个文件的名字改一下

Spark2.X集群运行模式

Spark2.X集群运行模式

配置slaves

Spark2.X集群运行模式

配置spark-env.sh

Spark2.X集群运行模式

Spark2.X集群运行模式

export JAVA_HOME=/opt/modules/jdk1..0_60
export SCALA_HOME=/opt/modules/scala-2.11. SPARK_MASTER_HOST=bigdata-pro02.kfk.com
SPARK_MASTER_PORT=
SPARK_MASTER_WEBUI_PORT=
SPARK_WORKER_CORES=
SPARK_WORKER_MEMORY=1g
SPARK_WORKER_PORT=
SPARK_WORKER_WEBUI_PORT= SPARK_CONF_DIR=/opt/modules/spark-2.2.-bin/conf

将spark 配置分发到其他节点并修改每个节点特殊配置

scp -r spark-2.2.0-bin bigdata-pro01.kfk.com:/opt/modules/

scp -r spark-2.2.0-bin bigdata-pro03.kfk.com:/opt/modules/

Spark2.X集群运行模式

Spark2.X集群运行模式

http://bigdata-pro02.kfk.com:8080/

在浏览器打开这个页面

Spark2.X集群运行模式

客户端测试

bin/spark-shell --master spark://bigdata-pro02.kfk.com:7077

Spark2.X集群运行模式

执行一个job

Spark2.X集群运行模式

Spark2.X集群运行模式

Spark2.X集群运行模式

点进去看看

Spark2.X集群运行模式

Spark2.X集群运行模式

bin/spark-submit --master spark://bigdata-pro02.kfk.com:7077 --deploy-mode cluster /opt/jars/sparkStu.jar  file:///opt/datas/stu.txt

Spark2.X集群运行模式

可以看到报错了!!!!

我们应该使用这个模式

Spark2.X集群运行模式

Spark2.X集群运行模式

Spark2.X集群运行模式

Spark2.X集群运行模式

Spark2.X集群运行模式

启动一下yarnSpark2.X集群运行模式

http://bigdata-pro01.kfk.com:8088/cluster

Spark2.X集群运行模式

Spark2.X集群运行模式

Spark2.X集群运行模式

我们就把HADOOP_CONF_DIR配置近来

Spark2.X集群运行模式

其他两个节点也一样。

再次运行,还是报错了

Spark2.X集群运行模式

[kfk@bigdata-pro02 spark-2.2.-bin]$  bin/spark-shell --master yarn --deploy-mode client
Setting default log level to "WARN".
To adjust logging level use sc.setLogLevel(newLevel). For SparkR, use setLogLevel(newLevel).
// :: WARN NativeCodeLoader: Unable to load native-hadoop library for your platform... using builtin-java classes where applicable
// :: WARN Client: Neither spark.yarn.jars nor spark.yarn.archive is set, falling back to uploading libraries under SPARK_HOME.
// :: ERROR SparkContext: Error initializing SparkContext.
org.apache.spark.SparkException: Yarn application has already ended! It might have been killed or unable to launch application master.
at org.apache.spark.scheduler.cluster.YarnClientSchedulerBackend.waitForApplication(YarnClientSchedulerBackend.scala:)
at org.apache.spark.scheduler.cluster.YarnClientSchedulerBackend.start(YarnClientSchedulerBackend.scala:)
at org.apache.spark.scheduler.TaskSchedulerImpl.start(TaskSchedulerImpl.scala:)
at org.apache.spark.SparkContext.<init>(SparkContext.scala:)
at org.apache.spark.SparkContext$.getOrCreate(SparkContext.scala:)
at org.apache.spark.sql.SparkSession$Builder$$anonfun$.apply(SparkSession.scala:)
at org.apache.spark.sql.SparkSession$Builder$$anonfun$.apply(SparkSession.scala:)
at scala.Option.getOrElse(Option.scala:)
at org.apache.spark.sql.SparkSession$Builder.getOrCreate(SparkSession.scala:)
at org.apache.spark.repl.Main$.createSparkSession(Main.scala:)
at $line3.$read$$iw$$iw.<init>(<console>:)
at $line3.$read$$iw.<init>(<console>:)
at $line3.$read.<init>(<console>:)
at $line3.$read$.<init>(<console>:)
at $line3.$read$.<clinit>(<console>)
at $line3.$eval$.$print$lzycompute(<console>:)
at $line3.$eval$.$print(<console>:)
at $line3.$eval.$print(<console>)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:)
at java.lang.reflect.Method.invoke(Method.java:)
at scala.tools.nsc.interpreter.IMain$ReadEvalPrint.call(IMain.scala:)
at scala.tools.nsc.interpreter.IMain$Request.loadAndRun(IMain.scala:)
at scala.tools.nsc.interpreter.IMain$WrappedRequest$$anonfun$loadAndRunReq$.apply(IMain.scala:)
at scala.tools.nsc.interpreter.IMain$WrappedRequest$$anonfun$loadAndRunReq$.apply(IMain.scala:)
at scala.reflect.internal.util.ScalaClassLoader$class.asContext(ScalaClassLoader.scala:)
at scala.reflect.internal.util.AbstractFileClassLoader.asContext(AbstractFileClassLoader.scala:)
at scala.tools.nsc.interpreter.IMain$WrappedRequest.loadAndRunReq(IMain.scala:)
at scala.tools.nsc.interpreter.IMain.interpret(IMain.scala:)
at scala.tools.nsc.interpreter.IMain.interpret(IMain.scala:)
at scala.tools.nsc.interpreter.ILoop.interpretStartingWith(ILoop.scala:)
at scala.tools.nsc.interpreter.ILoop.command(ILoop.scala:)
at scala.tools.nsc.interpreter.ILoop.processLine(ILoop.scala:)
at org.apache.spark.repl.SparkILoop$$anonfun$initializeSpark$.apply$mcV$sp(SparkILoop.scala:)
at org.apache.spark.repl.SparkILoop$$anonfun$initializeSpark$.apply(SparkILoop.scala:)
at org.apache.spark.repl.SparkILoop$$anonfun$initializeSpark$.apply(SparkILoop.scala:)
at scala.tools.nsc.interpreter.IMain.beQuietDuring(IMain.scala:)
at org.apache.spark.repl.SparkILoop.initializeSpark(SparkILoop.scala:)
at org.apache.spark.repl.SparkILoop.loadFiles(SparkILoop.scala:)
at scala.tools.nsc.interpreter.ILoop$$anonfun$process$.apply$mcZ$sp(ILoop.scala:)
at scala.tools.nsc.interpreter.ILoop$$anonfun$process$.apply(ILoop.scala:)
at scala.tools.nsc.interpreter.ILoop$$anonfun$process$.apply(ILoop.scala:)
at scala.reflect.internal.util.ScalaClassLoader$.savingContextLoader(ScalaClassLoader.scala:)
at scala.tools.nsc.interpreter.ILoop.process(ILoop.scala:)
at org.apache.spark.repl.Main$.doMain(Main.scala:)
at org.apache.spark.repl.Main$.main(Main.scala:)
at org.apache.spark.repl.Main.main(Main.scala)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:)
at java.lang.reflect.Method.invoke(Method.java:)
at org.apache.spark.deploy.SparkSubmit$.org$apache$spark$deploy$SparkSubmit$$runMain(SparkSubmit.scala:)
at org.apache.spark.deploy.SparkSubmit$.doRunMain$(SparkSubmit.scala:)
at org.apache.spark.deploy.SparkSubmit$.submit(SparkSubmit.scala:)
at org.apache.spark.deploy.SparkSubmit$.main(SparkSubmit.scala:)
at org.apache.spark.deploy.SparkSubmit.main(SparkSubmit.scala)
// :: WARN YarnSchedulerBackend$YarnSchedulerEndpoint: Attempted to request executors before the AM has registered!
// :: WARN MetricsSystem: Stopping a MetricsSystem that is not running
org.apache.spark.SparkException: Yarn application has already ended! It might have been killed or unable to launch application master.
at org.apache.spark.scheduler.cluster.YarnClientSchedulerBackend.waitForApplication(YarnClientSchedulerBackend.scala:)
at org.apache.spark.scheduler.cluster.YarnClientSchedulerBackend.start(YarnClientSchedulerBackend.scala:)
at org.apache.spark.scheduler.TaskSchedulerImpl.start(TaskSchedulerImpl.scala:)
at org.apache.spark.SparkContext.<init>(SparkContext.scala:)
at org.apache.spark.SparkContext$.getOrCreate(SparkContext.scala:)
at org.apache.spark.sql.SparkSession$Builder$$anonfun$.apply(SparkSession.scala:)
at org.apache.spark.sql.SparkSession$Builder$$anonfun$.apply(SparkSession.scala:)
at scala.Option.getOrElse(Option.scala:)
at org.apache.spark.sql.SparkSession$Builder.getOrCreate(SparkSession.scala:)
at org.apache.spark.repl.Main$.createSparkSession(Main.scala:)
... elided
<console>:: error: not found: value spark
import spark.implicits._
^
<console>:: error: not found: value spark
import spark.sql
^
Welcome to
____ __
/ __/__ ___ _____/ /__
_\ \/ _ \/ _ `/ __/ '_/
/___/ .__/\_,_/_/ /_/\_\ version 2.2.
/_/ Using Scala version 2.11. (Java HotSpot(TM) -Bit Server VM, Java 1.8.0_60)
Type in expressions to have them evaluated.
Type :help for more information.

Spark2.X集群运行模式

我们来修改这个配置文件yarn-site.xml

Spark2.X集群运行模式

加上这两项

Spark2.X集群运行模式

 <property>
<name>yarn.nodemanager.pmem-check-enabled</name>
<value>false</value>
</property> <property>
<name>yarn.nodemanager.vmem-check-enabled</name>
<value>false</value>
</property>

其他两个节点的yarn-site.xml也是一样,这里我就不多说了。或者是我们把节点2的这个文件分发给另外两个节点也是可以的。

不过分发之前先把yarn停下来

Spark2.X集群运行模式

Spark2.X集群运行模式

还有一点细节一定要注意,报这个错误其实原因有很多的,不单单是说内存不够的问题,内存不够只是其中一个原因,还有一个细节我们容易漏掉的就jdk版本一定要跟spark-env.sh的一致

尤其要注意hadoop里面的这两个文件

Spark2.X集群运行模式

Spark2.X集群运行模式

我这里是以其中一个节点来说明,其他两个节点的hadoop配置文件也是这样修改,因为我们之前的hadoop是用jdk1.7版本的,spark改用1.8版本了,所以关于hadoop的所有配置文件有关配置jdk的都某要改成1.8

我们再次启动yarn

Spark2.X集群运行模式

启动spark(由于考虑到spark比较消耗内存,我就把spark的master切换到节点1去了,因为节点1我给他分配了4G内存)

记得修改spark-env.sh文件(3个节点都改)

Spark2.X集群运行模式

Spark2.X集群运行模式

Spark2.X集群运行模式

Spark2.X集群运行模式

Spark2.X集群运行模式

Spark2.X集群运行模式

Spark2.X集群运行模式

Spark2.X集群运行模式

Spark2.X集群运行模式

进行分组求和

Spark2.X集群运行模式

Spark2.X集群运行模式

退出

Spark2.X集群运行模式

Spark2.X集群运行模式

用submit模式跑一下

Spark2.X集群运行模式

可以看到报错了

Spark2.X集群运行模式

[kfk@bigdata-pro01 spark-2.2.-bin]$ bin/spark-submit --class com.spark.test.Test --master yarn --deploy-mode cluster /opt/jars/sparkStu.jar  file:///opt/datas/stu.txt
// :: WARN NativeCodeLoader: Unable to load native-hadoop library for your platform... using builtin-java classes where applicable
// :: INFO Client: Requesting a new application from cluster with NodeManagers
// :: INFO Client: Verifying our application has not requested more than the maximum memory capability of the cluster ( MB per container)
// :: INFO Client: Will allocate AM container, with MB memory including MB overhead
// :: INFO Client: Setting up container launch context for our AM
// :: INFO Client: Setting up the launch environment for our AM container
// :: INFO Client: Preparing resources for our AM container
// :: WARN Client: Neither spark.yarn.jars nor spark.yarn.archive is set, falling back to uploading libraries under SPARK_HOME.
// :: INFO Client: Uploading resource file:/tmp/spark-edc616a1-10bf--9d7c-91a2430844f8/__spark_libs__6050155581866596916.zip -> hdfs://ns/user/kfk/.sparkStaging/application_1521167375207_0003/__spark_libs__6050155581866596916.zip
// :: INFO Client: Uploading resource file:/opt/jars/sparkStu.jar -> hdfs://ns/user/kfk/.sparkStaging/application_1521167375207_0003/sparkStu.jar
// :: INFO Client: Uploading resource file:/tmp/spark-edc616a1-10bf--9d7c-91a2430844f8/__spark_conf__6419799297331143395.zip -> hdfs://ns/user/kfk/.sparkStaging/application_1521167375207_0003/__spark_conf__.zip
// :: INFO SecurityManager: Changing view acls to: kfk
// :: INFO SecurityManager: Changing modify acls to: kfk
// :: INFO SecurityManager: Changing view acls groups to:
// :: INFO SecurityManager: Changing modify acls groups to:
// :: INFO SecurityManager: SecurityManager: authentication disabled; ui acls disabled; users with view permissions: Set(kfk); groups with view permissions: Set(); users with modify permissions: Set(kfk); groups with modify permissions: Set()
// :: INFO Client: Submitting application application_1521167375207_0003 to ResourceManager
// :: INFO YarnClientImpl: Submitted application application_1521167375207_0003
// :: INFO Client: Application report for application_1521167375207_0003 (state: ACCEPTED)
// :: INFO Client:
client token: N/A
diagnostics: N/A
ApplicationMaster host: N/A
ApplicationMaster RPC port: -
queue: default
start time:
final status: UNDEFINED
tracking URL: http://bigdata-pro01.kfk.com:8088/proxy/application_1521167375207_0003/
user: kfk
// :: INFO Client: Application report for application_1521167375207_0003 (state: ACCEPTED)
// :: INFO Client: Application report for application_1521167375207_0003 (state: ACCEPTED)
// :: INFO Client: Application report for application_1521167375207_0003 (state: ACCEPTED)
// :: INFO Client: Application report for application_1521167375207_0003 (state: ACCEPTED)
// :: INFO Client: Application report for application_1521167375207_0003 (state: ACCEPTED)
// :: INFO Client: Application report for application_1521167375207_0003 (state: ACCEPTED)
// :: INFO Client: Application report for application_1521167375207_0003 (state: ACCEPTED)
// :: INFO Client: Application report for application_1521167375207_0003 (state: ACCEPTED)
// :: INFO Client: Application report for application_1521167375207_0003 (state: ACCEPTED)
// :: INFO Client: Application report for application_1521167375207_0003 (state: ACCEPTED)
// :: INFO Client: Application report for application_1521167375207_0003 (state: ACCEPTED)
// :: INFO Client: Application report for application_1521167375207_0003 (state: ACCEPTED)
// :: INFO Client: Application report for application_1521167375207_0003 (state: ACCEPTED)
// :: INFO Client: Application report for application_1521167375207_0003 (state: ACCEPTED)
// :: INFO Client: Application report for application_1521167375207_0003 (state: ACCEPTED)
// :: INFO Client: Application report for application_1521167375207_0003 (state: ACCEPTED)
// :: INFO Client: Application report for application_1521167375207_0003 (state: ACCEPTED)
// :: INFO Client: Application report for application_1521167375207_0003 (state: ACCEPTED)
// :: INFO Client: Application report for application_1521167375207_0003 (state: ACCEPTED)
// :: INFO Client: Application report for application_1521167375207_0003 (state: ACCEPTED)
// :: INFO Client: Application report for application_1521167375207_0003 (state: ACCEPTED)
// :: INFO Client: Application report for application_1521167375207_0003 (state: ACCEPTED)
// :: INFO Client: Application report for application_1521167375207_0003 (state: ACCEPTED)
// :: INFO Client: Application report for application_1521167375207_0003 (state: ACCEPTED)
// :: INFO Client: Application report for application_1521167375207_0003 (state: ACCEPTED)
// :: INFO Client: Application report for application_1521167375207_0003 (state: ACCEPTED)
// :: INFO Client: Application report for application_1521167375207_0003 (state: ACCEPTED)
// :: INFO Client: Application report for application_1521167375207_0003 (state: ACCEPTED)
// :: INFO Client: Application report for application_1521167375207_0003 (state: ACCEPTED)
// :: INFO Client: Application report for application_1521167375207_0003 (state: ACCEPTED)
// :: INFO Client: Application report for application_1521167375207_0003 (state: ACCEPTED)
// :: INFO Client: Application report for application_1521167375207_0003 (state: ACCEPTED)
// :: INFO Client: Application report for application_1521167375207_0003 (state: ACCEPTED)
// :: INFO Client: Application report for application_1521167375207_0003 (state: ACCEPTED)
// :: INFO Client: Application report for application_1521167375207_0003 (state: ACCEPTED)
// :: INFO Client: Application report for application_1521167375207_0003 (state: FAILED)
// :: INFO Client:
client token: N/A
diagnostics: Application application_1521167375207_0003 failed times due to AM Container for appattempt_1521167375207_0003_000002 exited with exitCode: -
For more detailed output, check application tracking page:http://bigdata-pro01.kfk.com:8088/proxy/application_1521167375207_0003/Then, click on links to logs of each attempt.
Diagnostics: File does not exist: hdfs://ns/user/kfk/.sparkStaging/application_1521167375207_0003/__spark_libs__6050155581866596916.zip
java.io.FileNotFoundException: File does not exist: hdfs://ns/user/kfk/.sparkStaging/application_1521167375207_0003/__spark_libs__6050155581866596916.zip
at org.apache.hadoop.hdfs.DistributedFileSystem$.doCall(DistributedFileSystem.java:)
at org.apache.hadoop.hdfs.DistributedFileSystem$.doCall(DistributedFileSystem.java:)
at org.apache.hadoop.fs.FileSystemLinkResolver.resolve(FileSystemLinkResolver.java:)
at org.apache.hadoop.hdfs.DistributedFileSystem.getFileStatus(DistributedFileSystem.java:)
at org.apache.hadoop.yarn.util.FSDownload.copy(FSDownload.java:)
at org.apache.hadoop.yarn.util.FSDownload.access$(FSDownload.java:)
at org.apache.hadoop.yarn.util.FSDownload$.run(FSDownload.java:)
at org.apache.hadoop.yarn.util.FSDownload$.run(FSDownload.java:)
at java.security.AccessController.doPrivileged(Native Method)
at javax.security.auth.Subject.doAs(Subject.java:)
at org.apache.hadoop.security.UserGroupInformation.doAs(UserGroupInformation.java:)
at org.apache.hadoop.yarn.util.FSDownload.call(FSDownload.java:)
at org.apache.hadoop.yarn.util.FSDownload.call(FSDownload.java:)
at java.util.concurrent.FutureTask.run(FutureTask.java:)
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:)
at java.util.concurrent.FutureTask.run(FutureTask.java:)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:)
at java.lang.Thread.run(Thread.java:) Failing this attempt. Failing the application.
ApplicationMaster host: N/A
ApplicationMaster RPC port: -
queue: default
start time:
final status: FAILED
tracking URL: http://bigdata-pro01.kfk.com:8088/cluster/app/application_1521167375207_0003
user: kfk
Exception in thread "main" org.apache.spark.SparkException: Application application_1521167375207_0003 finished with failed status
at org.apache.spark.deploy.yarn.Client.run(Client.scala:)
at org.apache.spark.deploy.yarn.Client$.main(Client.scala:)
at org.apache.spark.deploy.yarn.Client.main(Client.scala)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:)
at java.lang.reflect.Method.invoke(Method.java:)
at org.apache.spark.deploy.SparkSubmit$.org$apache$spark$deploy$SparkSubmit$$runMain(SparkSubmit.scala:)
at org.apache.spark.deploy.SparkSubmit$.doRunMain$(SparkSubmit.scala:)
at org.apache.spark.deploy.SparkSubmit$.submit(SparkSubmit.scala:)
at org.apache.spark.deploy.SparkSubmit$.main(SparkSubmit.scala:)
at org.apache.spark.deploy.SparkSubmit.main(SparkSubmit.scala)
// :: INFO ShutdownHookManager: Shutdown hook called
// :: INFO ShutdownHookManager: Deleting directory /tmp/spark-edc616a1-10bf--9d7c-91a2430844f8
[kfk@bigdata-pro01 spark-2.2.-bin]$

我们在idea把sparkStu的源码打开

Spark2.X集群运行模式

改一下这里

Spark2.X集群运行模式

Spark2.X集群运行模式

Spark2.X集群运行模式

把包完之后我们把这个包再次上传(为了保险,我把3个节点都上传了,可能我比较SB)

先把原来的包干掉

Spark2.X集群运行模式

Spark2.X集群运行模式

Spark2.X集群运行模式

现在上传

Spark2.X集群运行模式

Spark2.X集群运行模式

Spark2.X集群运行模式

再跑一次

Spark2.X集群运行模式

Spark2.X集群运行模式

可以看到成功了

[kfk@bigdata-pro01 spark-2.2.-bin]$ bin/spark-submit --class com.spark.test.Test --master yarn --deploy-mode cluster /opt/jars/sparkStu.jar  file:///opt/datas/stu.txt
// :: WARN NativeCodeLoader: Unable to load native-hadoop library for your platform... using builtin-java classes where applicable
// :: INFO Client: Requesting a new application from cluster with NodeManagers
// :: INFO Client: Verifying our application has not requested more than the maximum memory capability of the cluster ( MB per container)
// :: INFO Client: Will allocate AM container, with MB memory including MB overhead
// :: INFO Client: Setting up container launch context for our AM
// :: INFO Client: Setting up the launch environment for our AM container
// :: INFO Client: Preparing resources for our AM container
// :: WARN Client: Neither spark.yarn.jars nor spark.yarn.archive is set, falling back to uploading libraries under SPARK_HOME.
// :: INFO Client: Uploading resource file:/tmp/spark-43f281a9-034a-424b--d6d00addfff6/__spark_libs__8012713420631475441.zip -> hdfs://ns/user/kfk/.sparkStaging/application_1521167375207_0004/__spark_libs__8012713420631475441.zip
// :: INFO Client: Uploading resource file:/opt/jars/sparkStu.jar -> hdfs://ns/user/kfk/.sparkStaging/application_1521167375207_0004/sparkStu.jar
// :: INFO Client: Uploading resource file:/tmp/spark-43f281a9-034a-424b--d6d00addfff6/__spark_conf__8776342149712582279.zip -> hdfs://ns/user/kfk/.sparkStaging/application_1521167375207_0004/__spark_conf__.zip
// :: INFO SecurityManager: Changing view acls to: kfk
// :: INFO SecurityManager: Changing modify acls to: kfk
// :: INFO SecurityManager: Changing view acls groups to:
// :: INFO SecurityManager: Changing modify acls groups to:
// :: INFO SecurityManager: SecurityManager: authentication disabled; ui acls disabled; users with view permissions: Set(kfk); groups with view permissions: Set(); users with modify permissions: Set(kfk); groups with modify permissions: Set()
// :: INFO Client: Submitting application application_1521167375207_0004 to ResourceManager
// :: INFO YarnClientImpl: Submitted application application_1521167375207_0004
// :: INFO Client: Application report for application_1521167375207_0004 (state: ACCEPTED)
// :: INFO Client:
client token: N/A
diagnostics: N/A
ApplicationMaster host: N/A
ApplicationMaster RPC port: -
queue: default
start time:
final status: UNDEFINED
tracking URL: http://bigdata-pro01.kfk.com:8088/proxy/application_1521167375207_0004/
user: kfk
// :: INFO Client: Application report for application_1521167375207_0004 (state: ACCEPTED)
// :: INFO Client: Application report for application_1521167375207_0004 (state: ACCEPTED)
// :: INFO Client: Application report for application_1521167375207_0004 (state: ACCEPTED)
// :: INFO Client: Application report for application_1521167375207_0004 (state: ACCEPTED)
// :: INFO Client: Application report for application_1521167375207_0004 (state: ACCEPTED)
// :: INFO Client: Application report for application_1521167375207_0004 (state: ACCEPTED)
// :: INFO Client: Application report for application_1521167375207_0004 (state: ACCEPTED)
// :: INFO Client: Application report for application_1521167375207_0004 (state: ACCEPTED)
// :: INFO Client: Application report for application_1521167375207_0004 (state: ACCEPTED)
// :: INFO Client: Application report for application_1521167375207_0004 (state: ACCEPTED)
// :: INFO Client: Application report for application_1521167375207_0004 (state: ACCEPTED)
// :: INFO Client: Application report for application_1521167375207_0004 (state: ACCEPTED)
// :: INFO Client: Application report for application_1521167375207_0004 (state: ACCEPTED)
// :: INFO Client: Application report for application_1521167375207_0004 (state: ACCEPTED)
// :: INFO Client: Application report for application_1521167375207_0004 (state: ACCEPTED)
// :: INFO Client: Application report for application_1521167375207_0004 (state: ACCEPTED)
// :: INFO Client: Application report for application_1521167375207_0004 (state: ACCEPTED)
// :: INFO Client: Application report for application_1521167375207_0004 (state: RUNNING)
// :: INFO Client:
client token: N/A
diagnostics: N/A
ApplicationMaster host: 192.168.86.152
ApplicationMaster RPC port:
queue: default
start time:
final status: UNDEFINED
tracking URL: http://bigdata-pro01.kfk.com:8088/proxy/application_1521167375207_0004/
user: kfk
// :: INFO Client: Application report for application_1521167375207_0004 (state: RUNNING)
// :: INFO Client: Application report for application_1521167375207_0004 (state: RUNNING)
// :: INFO Client: Application report for application_1521167375207_0004 (state: RUNNING)
// :: INFO Client: Application report for application_1521167375207_0004 (state: RUNNING)
// :: INFO Client: Application report for application_1521167375207_0004 (state: RUNNING)
// :: INFO Client: Application report for application_1521167375207_0004 (state: RUNNING)
// :: INFO Client: Application report for application_1521167375207_0004 (state: RUNNING)
// :: INFO Client: Application report for application_1521167375207_0004 (state: RUNNING)
// :: INFO Client: Application report for application_1521167375207_0004 (state: RUNNING)
// :: INFO Client: Application report for application_1521167375207_0004 (state: RUNNING)
// :: INFO Client: Application report for application_1521167375207_0004 (state: RUNNING)
// :: INFO Client: Application report for application_1521167375207_0004 (state: RUNNING)
// :: INFO Client: Application report for application_1521167375207_0004 (state: RUNNING)
// :: INFO Client: Application report for application_1521167375207_0004 (state: RUNNING)
// :: INFO Client: Application report for application_1521167375207_0004 (state: RUNNING)
// :: INFO Client: Application report for application_1521167375207_0004 (state: RUNNING)
// :: INFO Client: Application report for application_1521167375207_0004 (state: RUNNING)
// :: INFO Client: Application report for application_1521167375207_0004 (state: RUNNING)
// :: INFO Client: Application report for application_1521167375207_0004 (state: RUNNING)
// :: INFO Client: Application report for application_1521167375207_0004 (state: RUNNING)
// :: INFO Client: Application report for application_1521167375207_0004 (state: RUNNING)
// :: INFO Client: Application report for application_1521167375207_0004 (state: RUNNING)
// :: INFO Client: Application report for application_1521167375207_0004 (state: RUNNING)
// :: INFO Client: Application report for application_1521167375207_0004 (state: RUNNING)
// :: INFO Client: Application report for application_1521167375207_0004 (state: RUNNING)
// :: INFO Client: Application report for application_1521167375207_0004 (state: RUNNING)
// :: INFO Client: Application report for application_1521167375207_0004 (state: RUNNING)
// :: INFO Client: Application report for application_1521167375207_0004 (state: RUNNING)
// :: INFO Client: Application report for application_1521167375207_0004 (state: RUNNING)
// :: INFO Client: Application report for application_1521167375207_0004 (state: RUNNING)
// :: INFO Client: Application report for application_1521167375207_0004 (state: RUNNING)
// :: INFO Client: Application report for application_1521167375207_0004 (state: RUNNING)
// :: INFO Client: Application report for application_1521167375207_0004 (state: RUNNING)
// :: INFO Client: Application report for application_1521167375207_0004 (state: RUNNING)
// :: INFO Client: Application report for application_1521167375207_0004 (state: RUNNING)
// :: INFO Client: Application report for application_1521167375207_0004 (state: RUNNING)
// :: INFO Client: Application report for application_1521167375207_0004 (state: RUNNING)
// :: INFO Client: Application report for application_1521167375207_0004 (state: RUNNING)
// :: INFO Client: Application report for application_1521167375207_0004 (state: RUNNING)
// :: INFO Client: Application report for application_1521167375207_0004 (state: RUNNING)
// :: INFO Client: Application report for application_1521167375207_0004 (state: RUNNING)
// :: INFO Client: Application report for application_1521167375207_0004 (state: RUNNING)
// :: INFO Client: Application report for application_1521167375207_0004 (state: RUNNING)
// :: INFO Client: Application report for application_1521167375207_0004 (state: RUNNING)
// :: INFO Client: Application report for application_1521167375207_0004 (state: RUNNING)
// :: INFO Client: Application report for application_1521167375207_0004 (state: RUNNING)
// :: INFO Client: Application report for application_1521167375207_0004 (state: RUNNING)
// :: INFO Client: Application report for application_1521167375207_0004 (state: RUNNING)
// :: INFO Client: Application report for application_1521167375207_0004 (state: RUNNING)
// :: INFO Client: Application report for application_1521167375207_0004 (state: FINISHED)
// :: INFO Client:
client token: N/A
diagnostics: N/A
ApplicationMaster host: 192.168.86.152
ApplicationMaster RPC port:
queue: default
start time:
final status: SUCCEEDED
tracking URL: http://bigdata-pro01.kfk.com:8088/proxy/application_1521167375207_0004/A
user: kfk
// :: INFO ShutdownHookManager: Shutdown hook called
// :: INFO ShutdownHookManager: Deleting directory /tmp/spark-43f281a9-034a-424b--d6d00addfff6
[kfk@bigdata-pro01 spark-2.2.-bin]$

Spark2.X集群运行模式

在这里我补充一下,我们能看见终端打印这么多日志,是因为修改了这个文件

Spark2.X集群运行模式

Spark2.X集群运行模式的更多相关文章

  1. 新闻实时分析系统 Spark2&period;X集群运行模式

    1.几种运行模式介绍 Spark几种运行模式: 1)Local 2)Standalone 3)Yarn 4)Mesos 下载IDEA并安装,可以百度一下免费文档. 2.spark Standalone ...

  2. 新闻网大数据实时分析可视化系统项目——16、Spark2&period;X集群运行模式

    1.几种运行模式介绍 Spark几种运行模式: 1)Local 2)Standalone 3)Yarn 4)Mesos 下载IDEA并安装,可以百度一下免费文档. 2.spark Standalone ...

  3. spark之scala程序开发&lpar;集群运行模式&rpar;:单词出现次数统计

    准备工作: 将运行Scala-Eclipse的机器节点(CloudDeskTop)内存调整至4G,因为需要在该节点上跑本地(local)Spark程序,本地Spark程序会启动Worker进程耗用大量 ...

  4. spark集群运行模式

    spark的集中运行模式 Local .Standalone.Yarn 关闭防火墙:systemctl stop firewalld.service 重启网络服务:systemctl restart ...

  5. Spark运行模式&lowbar;本地伪集群运行模式(单机模拟集群)

    这种运行模式,和Local[N]很像,不同的是,它会在单机启动多个进程来模拟集群下的分布式场景,而不像Local[N]这种多个线程只能在一个进程下委屈求全的共享资源.通常也是用来验证开发出来的应用程序 ...

  6. 简单说明hadoop集群运行三种模式和配置文件

    Hadoop的运行模式分为3种:本地运行模式,伪分布运行模式,集群运行模式,相应概念如下: 1.独立模式即本地运行模式(standalone或local mode)无需运行任何守护进程(daemon) ...

  7. hadoop本地运行与集群运行

    开发环境: windows10+伪分布式(虚拟机组成的集群)+IDEA(不需要装插件) 介绍: 本地开发,本地debug,不需要启动集群,不需要在集群启动hdfs yarn 需要准备什么: 1/配置w ...

  8. Spark新手入门——3&period;Spark集群&lpar;standalone模式&rpar;安装

    主要包括以下三部分,本文为第三部分: 一. Scala环境准备 查看二. Hadoop集群(伪分布模式)安装 查看三. Spark集群(standalone模式)安装 Spark集群(standalo ...

  9. &lbrack;spark&rsqb;-Spark2&period;x集群搭建与参数详解

    在前面的Spark发展历程和基本概念中介绍了Spark的一些基本概念,熟悉了这些基本概念对于集群的搭建是很有必要的.我们可以了解到每个参数配置的作用是什么.这里将详细介绍Spark集群搭建以及xml参 ...

随机推荐

  1. 执行jar文件生成pdf报错,Unsupported URL &lt&semi;file&colon;&sol;&sol;&sol;home

    java -Djava.library.path=/usr/local/lib/ruby/gems/1.8/gems/sharp_office-1.0.1/ext/sigar -jar /usr/lo ...

  2. 正则表达式&lpar;&sol;&lbrack;&Hat;0-9&rsqb;&sol;g&comma;&&num;39&semi;&&num;39&semi;&rpar;中的&quot&semi;&sol;g&quot&semi;是什么意思 ?

    正则表达式(/[^0-9]/g,'')中的"/g"是什么意思 ?     表达式加上参数g之后,表明可以进行全局匹配,注意这里“可以”的含义.我们详细叙述: 1)对于表达式对象的e ...

  3. hdu1330(递推)

    题目链接:http://acm.hdu.edu.cn/showproblem.php?pid=1330 分析:经典问题,n 块相同的木板重叠,最多能够伸出桌面多远 对于n张卡片的最佳摆法,我们只需要在 ...

  4. JDK源码分析-Integer

    Integer是平时开发中最常用的类之一,但是如果没有研究过源码很多特性和坑可能就不知道,下面深入源码来分析一下Integer的设计和实现. Integer: 继承结构: -java.lang.Obj ...

  5. memcache常用命令

    一.memcached的基本命令(安装.卸载.启动.配置相关): -p 监听的端口 -l  连接的IP地址, 默认是本机   -d start 启动memcached服务 -d restart 重起m ...

  6. React Native &amp&semi; app demos

    React Native & app demos https://github.com/ReactNativeNews/React-Native-Apps https://github.com ...

  7. python 二分查找法

    @source_data:数据集 @binary_num:要查找的数 @mid:中间数的键值 def binary_search(source_data,search_num): #传入数据集计算中间 ...

  8. js的事件委托机制

    如今的JavaScript技术界里最火热的一项技术应该是‘事件委托(event delegation)’了.使用事件委托技术能让你避免对特定的每个节点添加事件监听器:相反,事件监听器是被添加到它们的父 ...

  9. 定时器NSTimer

    /** 添加定时器 */@property (nonatomic, strong) NSTimer *timer; - (void)addTimer{ // 2秒后,自己 调用nextImage方法 ...

  10. 微服务之springCloud-docker-feign-hystrix-ribbon(七)

    简介 在上一节中,我们讨论了feign+hystrix在项目开发中,除了考虑正常的调用之外,负载均衡和故障转移也是关注的重点,这也是feign + ribbon+hystrix的优势所在,本节我们就讨 ...