org.apache.spark.SparkException: Job aborted due to stage failure: Task 18 in stage 315.0 failed 8 times, most recent failure: Lost task 18.8 in stage 315.0 (TID 100793, qaphdd099.quantium.com.au.local): org.apache.spark.SparkException: Task failed while writing rows.

Apache's JIRA Issue Tracker | Jason Moore | 8 months ago
  1. 0

    [jira] [Created] (SPARK-14357) Tasks that fail due to CommitDeniedException (a side-effect of speculation) can cause job failure

    spark-issues | 8 months ago | Jason Moore (JIRA)
    org.apache.spark.SparkException: Job aborted due to stage failure: Task 18 in stage 315.0 failed 8 times, most recent failure: Lost task 18.8 in stage 315.0 (TID 100793, qaphdd099.quantium.com.au.local): org.apache.spark.SparkException: Task failed while writing rows.
  2. 0

    [jira] [Updated] (SPARK-14357) Tasks that fail due to CommitDeniedException (a side-effect of speculation) can cause job failure

    spark-issues | 8 months ago | Jason Moore (JIRA)
    org.apache.spark.SparkException: Job aborted due to stage failure: Task 18 in stage 315.0 failed 8 times, most recent failure: Lost task 18.8 in stage 315.0 (TID 100793, qaphdd099.quantium.com.au.local): org.apache.spark.SparkException: Task failed while writing rows.
  3. 0

    [jira] [Created] (SPARK-14357) Tasks that fail due to CommitDeniedException (a side-effect of speculation) can cause job failure

    spark-issues | 8 months ago | Jason Moore (JIRA)
    org.apache.spark.SparkException: Job aborted due to stage failure: Task 18 in stage 315.0 failed 8 times, most recent failure: Lost task 18.8 in stage 315.0 (TID 100793, qaphdd099.quantium.com.au.local): org.apache.spark.SparkException: Task failed while writing rows.
  4. Speed up your debug routine!

    Automated exception search integrated into your IDE

  5. 0

    [jira] [Updated] (SPARK-14357) Tasks that fail due to CommitDeniedException (a side-effect of speculation) can cause job failure

    spark-issues | 8 months ago | Jason Moore (JIRA)
    org.apache.spark.SparkException: Job aborted due to stage failure: Task 18 in stage 315.0 failed 8 times, most recent failure: Lost task 18.8 in stage 315.0 (TID 100793, qaphdd099.quantium.com.au.local): org.apache.spark.SparkException: Task failed while writing rows.
  6. 0

    Speculation can often result in a CommitDeniedException, but ideally this shouldn't result in the job failing. So changes were made along with SPARK-8167 to ensure that the CommitDeniedException is caught and given a failure reason that doesn't increment the failure count. However, I'm still noticing that this exception is causing jobs to fail using the 1.6.1 release version. {noformat} 16/04/04 11:36:02 ERROR InsertIntoHadoopFsRelation: Aborting job. org.apache.spark.SparkException: Job aborted due to stage failure: Task 18 in stage 315.0 failed 8 times, most recent failure: Lost task 18.8 in stage 315.0 (TID 100793, qaphdd099.quantium.com.au.local): org.apache.spark.SparkException: Task failed while writing rows. at org.apache.spark.sql.execution.datasources.DefaultWriterContainer.writeRows(WriterContainer.scala:272) at org.apache.spark.sql.execution.datasources.InsertIntoHadoopFsRelation$$anonfun$run$1$$anonfun$apply$mcV$sp$3.apply(InsertIntoHadoopFsRelation.scala:150) at org.apache.spark.sql.execution.datasources.InsertIntoHadoopFsRelation$$anonfun$run$1$$anonfun$apply$mcV$sp$3.apply(InsertIntoHadoopFsRelation.scala:150) at org.apache.spark.scheduler.ResultTask.runTask(ResultTask.scala:66) at org.apache.spark.scheduler.Task.run(Task.scala:89) at org.apache.spark.executor.Executor$TaskRunner.run(Executor.scala:214) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615) at java.lang.Thread.run(Thread.java:745) Caused by: java.lang.RuntimeException: Failed to commit task at org.apache.spark.sql.execution.datasources.DefaultWriterContainer.commitTask$1(WriterContainer.scala:287) at org.apache.spark.sql.execution.datasources.DefaultWriterContainer.writeRows(WriterContainer.scala:267) ... 8 more Caused by: org.apache.spark.executor.CommitDeniedException: attempt_201604041136_0315_m_000018_8: Not committed because the driver did not authorize commit at org.apache.spark.mapred.SparkHadoopMapRedUtil$.commitTask(SparkHadoopMapRedUtil.scala:135) at org.apache.spark.sql.execution.datasources.BaseWriterContainer.commitTask(WriterContainer.scala:219) at org.apache.spark.sql.execution.datasources.DefaultWriterContainer.commitTask$1(WriterContainer.scala:282) ... 9 more {noformat} It seems to me that the CommitDeniedException gets wrapped into a RuntimeException at [WriterContainer.scala#L286|https://github.com/apache/spark/blob/branch-1.6/sql/core/src/main/scala/org/apache/spark/sql/execution/datasources/WriterContainer.scala#L286] and then into a SparkException at [InsertIntoHadoopFsRelation.scala#L154|https://github.com/apache/spark/blob/branch-1.6/sql/core/src/main/scala/org/apache/spark/sql/execution/datasources/InsertIntoHadoopFsRelation.scala#L154] which results in it not being able to be handled properly at [Executor.scala#L290|https://github.com/apache/spark/blob/branch-1.6/core/src/main/scala/org/apache/spark/executor/Executor.scala#L290] The solution might be that this catch block should type match on the inner-most cause of an error?

    Apache's JIRA Issue Tracker | 8 months ago | Jason Moore
    org.apache.spark.SparkException: Job aborted due to stage failure: Task 18 in stage 315.0 failed 8 times, most recent failure: Lost task 18.8 in stage 315.0 (TID 100793, qaphdd099.quantium.com.au.local): org.apache.spark.SparkException: Task failed while writing rows.

    Not finding the right solution?
    Take a tour to get the most out of Samebug.

    Tired of useless tips?

    Automated exception search integrated into your IDE

    Root Cause Analysis

    1. org.apache.spark.executor.CommitDeniedException

      attempt_201604041136_0315_m_000018_8: Not committed because the driver did not authorize commit

      at org.apache.spark.mapred.SparkHadoopMapRedUtil$.commitTask()
    2. Spark
      SparkHadoopMapRedUtil$.commitTask
      1. org.apache.spark.mapred.SparkHadoopMapRedUtil$.commitTask(SparkHadoopMapRedUtil.scala:135)
      1 frame
    3. org.apache.spark
      InsertIntoHadoopFsRelation$$anonfun$run$1$$anonfun$apply$mcV$sp$3.apply
      1. org.apache.spark.sql.execution.datasources.BaseWriterContainer.commitTask(WriterContainer.scala:219)
      2. org.apache.spark.sql.execution.datasources.DefaultWriterContainer.commitTask$1(WriterContainer.scala:282)
      3. org.apache.spark.sql.execution.datasources.DefaultWriterContainer.writeRows(WriterContainer.scala:267)
      4. org.apache.spark.sql.execution.datasources.InsertIntoHadoopFsRelation$$anonfun$run$1$$anonfun$apply$mcV$sp$3.apply(InsertIntoHadoopFsRelation.scala:150)
      5. org.apache.spark.sql.execution.datasources.InsertIntoHadoopFsRelation$$anonfun$run$1$$anonfun$apply$mcV$sp$3.apply(InsertIntoHadoopFsRelation.scala:150)
      5 frames
    4. Spark
      Executor$TaskRunner.run
      1. org.apache.spark.scheduler.ResultTask.runTask(ResultTask.scala:66)
      2. org.apache.spark.scheduler.Task.run(Task.scala:89)
      3. org.apache.spark.executor.Executor$TaskRunner.run(Executor.scala:214)
      3 frames
    5. Java RT
      Thread.run
      1. java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)
      2. java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)
      3. java.lang.Thread.run(Thread.java:745)
      3 frames