有人能帮我修一下下面的代码吗
import pyspark
from pyspark import SparkContext, SparkConf
conf = SparkConf()
conf.setMaster('yarn-cluster')
conf.setAppName('test')
sc = SparkContext.getOrCreate()
r = sc.textFile("data.csv")
r.collect()
出现以下错误:
WARN cluster.YarnScheduler: Initial job has not accepted any resources; check your cluster UI to ensure that workers are registered and have sufficient resources
我希望收集结果会打印出来
谢谢
据我所知,这是一个悬而未决的问题,您可以在这里找到更多信息:
https://community.hortonworks.com/questions/37247/initial-job-has-not-accepted-any-resources.html
在这里:
https://github.com/databricks/spark-knowledgebase/issues/9
相关问题 更多 >
编程相关推荐