Error: java.io.FileNotFoundException: Path is not a file: /g6/hadoop/20190326
作者:互联网
跑mapreduce时,有报错Error: java.io.FileNotFoundException: Path is not a file: /g6/hadoop/20190326,以下是报错内容
19/03/26 21:28:08 INFO mapreduce.Job: map 0% reduce 0%
19/03/26 21:28:12 INFO mapreduce.Job: Task Id : attempt_1552051424310_0114_m_000000_0, Status : FAILED
Error: java.io.FileNotFoundException: Path is not a file: /g6/hadoop/20190326
at org.apache.hadoop.hdfs.server.namenode.INodeFile.valueOf(INodeFile.java:70)
at org.apache.hadoop.hdfs.server.namenode.INodeFile.valueOf(INodeFile.java:56)
at org.apache.hadoop.hdfs.server.namenode.FSNamesystem.getBlockLocationsUpdateTimes(FSNamesystem.java:1934)
at org.apache.hadoop.hdfs.server.namenode.FSNamesystem.getBlockLocationsInt(FSNamesystem.java:1875)
at org.apache.hadoop.hdfs.server.namenode.FSNamesystem.getBlockLocations(FSNamesystem.java:1855)
at org.apache.hadoop.hdfs.server.namenode.FSNamesystem.getBlockLocations(FSNamesystem.java:1827)
at org.apache.hadoop.hdfs.server.namenode.NameNodeRpcServer.getBlockLocations(NameNodeRpcServer.java:566)
at org.apache.hadoop.hdfs.server.namenode.AuthorizationProviderProxyClientProtocol.getBlockLocations(AuthorizationProviderPro
执行的命令是
process_data=20190326
hadoop jar hadoop_train-1.0.jar com.g609.hadoop.etl.driver.LogETLDriver /g6/hadoop/$process_data/ /g6/hadoop/access/output/$process_data
经过分析最终发现因为在输入路径/g6/hadoop/$process_data/ 最后又加了一个/ 把这个斜线去掉在执行就可以了
标签:hdfs,java,g6,hadoop,FSNamesystem,io,apache,namenode 来源: https://www.cnblogs.com/xuziyu/p/10604008.html