【问题标题】:spark python API java_gateway socket connection errorspark python API java_gateway套接字连接错误
【发布时间】:2013-09-30 08:30:51
【问题描述】:

我的集群是Spark-0.7.2 + Mesos-0.9。我用python写了一个spark程序,在本地模式下运行良好。但是当我在 mesos 上运行它时发生了一些错误。这是错误信息:

13/09/30 15:40:13 INFO TaskSetManager: Finished TID 13 in 242 ms (progress: 2/3)
13/09/30 15:40:13 INFO DAGScheduler: Completed ResultTask(4, 1)
send
Exception in thread "DAGScheduler" spark.SparkException: EOF reached before Python server acknowledged
        at spark.api.python.PythonAccumulatorParam.addInPlace(PythonRDD.scala:303)
        at spark.api.python.PythonAccumulatorParam.addInPlace(PythonRDD.scala:278)
        at spark.Accumulable.$plus$plus$eq(Accumulators.scala:52)
        at spark.Accumulators$$anonfun$add$2.apply(Accumulators.scala:235)
        at spark.Accumulators$$anonfun$add$2.apply(Accumulators.scala:233)
        at scala.collection.mutable.HashMap$$anonfun$foreach$1.apply(HashMap.scala:93)
        at scala.collection.mutable.HashMap$$anonfun$foreach$1.apply(HashMap.scala:93)
        at scala.collection.Iterator$class.foreach(Iterator.scala:660)
        at scala.collection.mutable.HashTable$$anon$1.foreach(HashTable.scala:157)
        at scala.collection.mutable.HashTable$class.foreachEntry(HashTable.scala:190)
        at scala.collection.mutable.HashMap.foreachEntry(HashMap.scala:43)
        at scala.collection.mutable.HashMap.foreach(HashMap.scala:93)
        at spark.Accumulators$.add(Accumulators.scala:233)
        at spark.scheduler.DAGScheduler.handleTaskCompletion(DAGScheduler.scala:494)
        at spark.scheduler.DAGScheduler.processEvent(DAGScheduler.scala:300)
        at spark.scheduler.DAGScheduler.spark$scheduler$DAGScheduler$$run(DAGScheduler.scala:364)
        at spark.scheduler.DAGScheduler$$anon$1.run(DAGScheduler.scala:107)
13/09/30 15:40:13 INFO TaskSetManager: Finished TID 12 in 407 ms (progress: 3/3)

这种情况并非每次都会发生。似乎套接字连接不稳定。有人可以建议如何解决这个问题吗?

【问题讨论】:

  • 本地和远程机器有不同的Python版本吗?在将运行在 Python 2.7 上的驱动程序与运行 Python 2.6 的工作人员混合时,我已经看到了这个问题。
  • 我在所有计算机上安装了 Python-2.7 并修改了 .bashrc 文件。它们现在都在 Python-2.7 上运行。错误不会那么频繁地出现。

标签: python sockets apache-spark mesos


【解决方案1】:

我通过将 Java 8 更新到 U91 解决了这个问题

【讨论】:

    猜你喜欢
    • 2019-12-22
    • 1970-01-01
    • 2022-01-24
    • 2015-08-26
    • 1970-01-01
    • 2011-07-31
    • 2014-01-26
    • 1970-01-01
    • 2016-06-28
    相关资源
    最近更新 更多