【ERROR】 错误: 找不到或无法加载主类 End
Could not find or load main class
Application failed 2 times due to AM Container: exited with exitCode: 1
【ERROR】 : Error initializing SparkContext.
解决方案:
1. 创建 archive: jar cv0f -C $SPARK_HOME/jars/ .
2. 上传jar包到 HDFS: hdfs dfs -put /some/path/
3. 在中设置 =
hdfs:///some/path/
或者 =
hdfs:///some/path/*.jar
另外对于自己配置的yarn集群(内存空间有限的情况下),尽量减小内存设定,在中设置:
=512M
=512M
=512M