2022-04-28 21:58:35,001 INFO mapreduce.Job: Job job_1650260671325_0017 running in uber mode : false 2022-04-28 21:58:35,002 INFO mapreduce.Job: map 0% reduce 0% 2022-04-28 21:58:39,041 INFO mapreduce.Job: Task Id : attempt_1650260671325_0017_m_000000_0, Status : FAILED Error: java.lang.InterruptedException: Process failed with status code 139
at org.notmysock.tpcds.GenTable$DSDGen.map(GenTable.java:194) at org.notmysock.tpcds.GenTable$DSDGen.map(GenTable.java:163) at org.apache.hadoop.mapreduce.Mapper.run(Mapper.java:146) at org.apache.hadoop.mapred.MapTask.runNewMapper(MapTask.java:799) at org.apache.hadoop.mapred.MapTask.run(MapTask.java:347) at org.apache.hadoop.mapred.YarnChild$2.run(YarnChild.java:174) at java.security.AccessController.doPrivileged(Native Method) at javax.security.auth.Subject.doAs(Subject.java:422) at org.apache.hadoop.security.UserGroupInformation.doAs(UserGroupInformation.java:1730) at org.apache.hadoop.mapred.YarnChild.main(YarnChild.java:168)
Process p = Runtime.getRuntime().exec(cmd, null, new File("dsdgen/tools/")); int status = p.waitFor(); if(status != 0) { String err = readToString(p.getErrorStream()); throw new InterruptedException("Process failed with status code " + status + "\n" + err); }
而错误又恰好是从这里出来的,于是又回去研究 139 这个状态码。
139表示Too big row,按照理解应该是命令行太长了,于是我重新查看了之前为诊断问题添加的日志,注意到程序中使用的目录用的是相对路径”.”,对于一个MapReduce程序来说,这个路径就是Container的路径,长度很长。