hadoop尝试使用jdk install directory作为可执行命令

zpf6vheq  于 2021-05-27  发布在  Hadoop
关注(0)|答案(0)|浏览(211)

我是hadoop新手,正在尝试运行第一个简单的“字数计算”示例。我遇到了与这里报告的相同的问题(但是那里的响应没有解决问题):无法在hadoop3.1.3中运行jar文件
java已安装到c:\jdk-15,并且已将其正确配置到hadoop-env.cmd文件中,如下所示:

@rem The java implementation to use.  Required.
set JAVA_HOME=c:\jdk-15

从下面的完整命令提示符转储中可以看到,我得到了以下错误。如果有人能猜出这里可能出了什么问题,或者有任何其他建议,我将不胜感激。
“下水集装箱”[2020-09-30 15:17:56.848]集装箱以非零出口代码1退出。stderr的最后4096字节:“'c:\jdk-15”'未被识别为内部或外部命令、可操作程序或批处理文件。

PS C:\hadoop-3.2.1\bin> hadoop jar ..\..\Hadoop\WordCount\wc.jar WordCount /test /WordCount/run1
2020-09-30 15:17:51,675 INFO client.RMProxy: Connecting to ResourceManager at /0.0.0.0:8032
2020-09-30 15:17:51,979 WARN mapreduce.JobResourceUploader: Hadoop command-line option parsing not performed. Implement the Tool interface and execute your application with ToolRunner to remedy this.
2020-09-30 15:17:52,052 INFO mapreduce.JobResourceUploader: Disabling Erasure Coding for path: /tmp/hadoop-yarn/staging/Admin/.staging/job_1601461031349_0008
2020-09-30 15:17:52,259 INFO sasl.SaslDataTransferClient: SASL encryption trust check: localHostTrusted = false, remoteHostTrusted = false
2020-09-30 15:17:52,426 INFO input.FileInputFormat: Total input files to process : 3
2020-09-30 15:17:52,592 INFO sasl.SaslDataTransferClient: SASL encryption trust check: localHostTrusted = false, remoteHostTrusted = false
2020-09-30 15:17:52,762 INFO sasl.SaslDataTransferClient: SASL encryption trust check: localHostTrusted = false, remoteHostTrusted = false
2020-09-30 15:17:52,829 INFO mapreduce.JobSubmitter: number of splits:3
2020-09-30 15:17:53,099 INFO sasl.SaslDataTransferClient: SASL encryption trust check: localHostTrusted = false, remoteHostTrusted = false
2020-09-30 15:17:53,190 INFO mapreduce.JobSubmitter: Submitting tokens for job: job_1601461031349_0008
2020-09-30 15:17:53,191 INFO mapreduce.JobSubmitter: Executing with tokens: []
2020-09-30 15:17:53,338 INFO conf.Configuration: resource-types.xml not found
2020-09-30 15:17:53,339 INFO resource.ResourceUtils: Unable to find 'resource-types.xml'.
2020-09-30 15:17:53,389 INFO impl.YarnClientImpl: Submitted application application_1601461031349_0008
2020-09-30 15:17:53,425 INFO mapreduce.Job: The url to track the job: http://CORSAIR:8088/proxy/application_1601461031349_0008/
2020-09-30 15:17:53,426 INFO mapreduce.Job: Running job: job_1601461031349_0008
2020-09-30 15:17:57,447 INFO mapreduce.Job: Job job_1601461031349_0008 running in uber mode : false
2020-09-30 15:17:57,448 INFO mapreduce.Job:  map 0% reduce 0%
2020-09-30 15:17:57,460 INFO mapreduce.Job: Job job_1601461031349_0008 failed with state FAILED due to: Application application_1601461031349_0008 failed 2 times due to AM Container for appattempt_1601461031349_0008_000002 exited with  exitCode: 1
Failing this attempt.Diagnostics: [2020-09-30 15:17:56.845]Exception from container-launch.
Container id: container_1601461031349_0008_02_000001
Exit code: 1
Shell output:         1 file(s) moved.
Setting up env variables
Setting up job resources
Copying debugging information

C:\tmp\hadoop-Admin\nm-local-dir\usercache\Admin\appcache\application_1601461031349_0008\container_1601461031349_0008_02_000001>rem Creating copy of launch script

C:\tmp\hadoop-Admin\nm-local-dir\usercache\Admin\appcache\application_1601461031349_0008\container_1601461031349_0008_02_000001>copy "launch_container.cmd" "C:/hadoop-3.2.1/logs/userlogs/application_1601461031349_0008/container_1601461031349_0008_02_000001/launch_container.cmd"
        1 file(s) copied.

C:\tmp\hadoop-Admin\nm-local-dir\usercache\Admin\appcache\application_1601461031349_0008\container_1601461031349_0008_02_000001>rem Determining directory contents

C:\tmp\hadoop-Admin\nm-local-dir\usercache\Admin\appcache\application_1601461031349_0008\container_1601461031349_0008_02_000001>dir  1>>"C:/hadoop-3.2.1/logs/userlogs/application_1601461031349_0008/container_1601461031349_0008_02_000001/directory.info"
Launching container

[2020-09-30 15:17:56.848]Container exited with a non-zero exit code 1. Last 4096 bytes of stderr :
'"C:\jdk-15"' is not recognized as an internal or external command,
operable program or batch file.

[2020-09-30 15:17:56.848]Container exited with a non-zero exit code 1. Last 4096 bytes of stderr :
'"C:\jdk-15"' is not recognized as an internal or external command,
operable program or batch file.

For more detailed output, check the application tracking page: http://CORSAIR:8088/cluster/app/application_1601461031349_0008 Then click on links to logs of each attempt.
. Failing the application.
2020-09-30 15:17:57,477 INFO mapreduce.Job: Counters: 0
PS C:\hadoop-3.2.1\bin>`

暂无答案!

目前还没有任何答案,快来回答吧!

相关问题