hadoop运行PI报错

许老许 2017-06-30 08:46:56
运行 hadoop jar ~/hadoop-2.5.2/hadoop/mapreduce/hadoop-mapreduce-examples-2.5.1.jar pi 10 10报异常
异常如下
17/06/30 05:30:45 WARN util.NativeCodeLoader: Unable to load native-hadoop library for your platform... using builtin-java classes where applicable
Wrote input for Map #0
Wrote input for Map #1
Wrote input for Map #2
Wrote input for Map #3
Wrote input for Map #4
Wrote input for Map #5
Wrote input for Map #6
Wrote input for Map #7
Wrote input for Map #8
Wrote input for Map #9
Starting Job
17/06/30 05:30:55 INFO client.RMProxy: Connecting to ResourceManager at master/192.168.10.100:18040
17/06/30 05:30:58 INFO input.FileInputFormat: Total input paths to process : 10
17/06/30 05:30:59 INFO mapreduce.JobSubmitter: number of splits:10
17/06/30 05:31:01 INFO mapreduce.JobSubmitter: Submitting tokens for job: job_1498821078171_0002
17/06/30 05:31:05 INFO impl.YarnClientImpl: Submitted application application_1498821078171_0002
17/06/30 05:31:05 INFO mapreduce.Job: The url to track the job: http://master:18088/proxy/application_1498821078171_0002/
17/06/30 05:31:05 INFO mapreduce.Job: Running job: job_1498821078171_0002
17/06/30 05:31:06 INFO mapreduce.Job: Job job_1498821078171_0002 running in uber mode : false
17/06/30 05:31:06 INFO mapreduce.Job: map 0% reduce 0%
17/06/30 05:31:06 INFO mapreduce.Job: Job job_1498821078171_0002 failed with state FAILED due to: Application application_1498821078171_0002 failed 2 times due to Error launching appattempt_1498821078171_0002_000002. Got exception: org.apache.hadoop.yarn.exceptions.YarnException: Unauthorized request to start container.
This token is expired. current time is 1498852238058 found 1498826466312
at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:57)
at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
at java.lang.reflect.Constructor.newInstance(Constructor.java:526)
at org.apache.hadoop.yarn.api.records.impl.pb.SerializedExceptionPBImpl.instantiateException(SerializedExceptionPBImpl.java:168)
at org.apache.hadoop.yarn.api.records.impl.pb.SerializedExceptionPBImpl.deSerialize(SerializedExceptionPBImpl.java:106)
at org.apache.hadoop.yarn.server.resourcemanager.amlauncher.AMLauncher.launch(AMLauncher.java:122)
at org.apache.hadoop.yarn.server.resourcemanager.amlauncher.AMLauncher.run(AMLauncher.java:249)
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)
. Failing the application.
17/06/30 05:31:06 INFO mapreduce.Job: Counters: 0
Job Finished in 12.162 seconds
java.io.FileNotFoundException: File does not exist: hdfs://master:9000/user/zkpk/QuasiMonteCarlo_1498825843150_1916352402/out/reduce-out
at org.apache.hadoop.hdfs.DistributedFileSystem$17.doCall(DistributedFileSystem.java:1072)
at org.apache.hadoop.hdfs.DistributedFileSystem$17.doCall(DistributedFileSystem.java:1064)
at org.apache.hadoop.fs.FileSystemLinkResolver.resolve(FileSystemLinkResolver.java:81)
at org.apache.hadoop.hdfs.DistributedFileSystem.getFileStatus(DistributedFileSystem.java:1064)
at org.apache.hadoop.io.SequenceFile$Reader.<init>(SequenceFile.java:1749)
at org.apache.hadoop.io.SequenceFile$Reader.<init>(SequenceFile.java:1773)
at org.apache.hadoop.examples.QuasiMonteCarlo.estimatePi(QuasiMonteCarlo.java:314)
at org.apache.hadoop.examples.QuasiMonteCarlo.run(QuasiMonteCarlo.java:354)
at org.apache.hadoop.util.ToolRunner.run(ToolRunner.java:70)
at org.apache.hadoop.examples.QuasiMonteCarlo.main(QuasiMonteCarlo.java:363)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:606)
at org.apache.hadoop.util.ProgramDriver$ProgramDescription.invoke(ProgramDriver.java:72)
at org.apache.hadoop.util.ProgramDriver.run(ProgramDriver.java:145)
at org.apache.hadoop.examples.ExampleDriver.main(ExampleDriver.java:74)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:606)
at org.apache.hadoop.util.RunJar.main(RunJar.java:212)
求大神教我,刚学的对着文档敲下来最后一步启动验证,运行PI报错了
...全文
1041 2 打赏 收藏 转发到动态 举报
写回复
用AI写文章
2 条回复
切换为时间正序
请发表友善的回复…
发表回复
qq_41084831 2019-03-24
  • 打赏
  • 举报
回复
您好,我在启动Hadoop集群运算pi值时,第一次已经运算成功,显示结果3.200000,但是第二次运行,就报错了,和您完全一样的错误,也重新配置了时间同步,但是第一次已经出来,应该也不是环境变量配置的问题,所以想请教一下您,您当时用了这三种方法就解决了问题吗?急切等待您的回复,谢谢。
许老许 2017-07-05
  • 打赏
  • 举报
回复
解决了 是 因为 1 一方面没有 同步时间 , 2 还有就是 没有 链接 外网 (这个应该是次要的) 3 最后是 运行 hadoop环境变量没有在 master上面配置

1,092

社区成员

发帖
与我相关
我的任务
社区描述
云计算服务器、网络、虚拟化相关讨论
社区管理员
  • 服务器
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告
暂无公告

试试用AI创作助手写篇文章吧