Hadoop:java.io.IOException:属性中没有有效的本地目录:mapred.local.dir

发布于 2024-12-08 13:41:37 字数 1789 浏览 0 评论 0原文

当我运行 hadoop 作业时,它失败并显示以下堆栈跟踪:

11/10/06 13:12:49 INFO mapred.FileInputFormat: Total input paths to process : 1
11/10/06 13:12:49 INFO mapred.JobClient: Cleaning up the staging area hdfs://localhost:54310/app/hadoop/tmp/mapred/staging/Har/.staging/job_201110051450_0007
11/10/06 13:12:49 ERROR streaming.StreamJob: Error Launching job : java.io.IOException: java.io.IOException: No valid local directories in property: mapred.local.dir
    at org.apache.hadoop.mapred.JobTracker.submitJob(JobTracker.java:3923)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
    at java.lang.reflect.Method.invoke(Method.java:597)
    at org.apache.hadoop.ipc.RPC$Server.call(RPC.java:523)
    at org.apache.hadoop.ipc.Server$Handler$1.run(Server.java:1383)
    at org.apache.hadoop.ipc.Server$Handler$1.run(Server.java:1379)
    at java.security.AccessController.doPrivileged(Native Method)
    at javax.security.auth.Subject.doAs(Subject.java:396)
    at org.apache.hadoop.security.UserGroupInformation.doAs(UserGroupInformation.java:1059)
    at org.apache.hadoop.ipc.Server$Handler.run(Server.java:1377)
Caused by: java.io.IOException: No valid local directories in property: mapred.local.dir
    at org.apache.hadoop.conf.Configuration.getLocalPath(Configuration.java:948)
    at org.apache.hadoop.mapred.JobConf.getLocalPath(JobConf.java:457)
    at org.apache.hadoop.mapred.JobInProgress.<init>(JobInProgress.java:401)
    at org.apache.hadoop.mapred.JobTracker.submitJob(JobTracker.java:3921)
    ... 11 more

Streaming Job Failed!

我怎样才能解决这个问题?

谢谢

when I run the hadoop job it fails with the following stacktrace:

11/10/06 13:12:49 INFO mapred.FileInputFormat: Total input paths to process : 1
11/10/06 13:12:49 INFO mapred.JobClient: Cleaning up the staging area hdfs://localhost:54310/app/hadoop/tmp/mapred/staging/Har/.staging/job_201110051450_0007
11/10/06 13:12:49 ERROR streaming.StreamJob: Error Launching job : java.io.IOException: java.io.IOException: No valid local directories in property: mapred.local.dir
    at org.apache.hadoop.mapred.JobTracker.submitJob(JobTracker.java:3923)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
    at java.lang.reflect.Method.invoke(Method.java:597)
    at org.apache.hadoop.ipc.RPC$Server.call(RPC.java:523)
    at org.apache.hadoop.ipc.Server$Handler$1.run(Server.java:1383)
    at org.apache.hadoop.ipc.Server$Handler$1.run(Server.java:1379)
    at java.security.AccessController.doPrivileged(Native Method)
    at javax.security.auth.Subject.doAs(Subject.java:396)
    at org.apache.hadoop.security.UserGroupInformation.doAs(UserGroupInformation.java:1059)
    at org.apache.hadoop.ipc.Server$Handler.run(Server.java:1377)
Caused by: java.io.IOException: No valid local directories in property: mapred.local.dir
    at org.apache.hadoop.conf.Configuration.getLocalPath(Configuration.java:948)
    at org.apache.hadoop.mapred.JobConf.getLocalPath(JobConf.java:457)
    at org.apache.hadoop.mapred.JobInProgress.<init>(JobInProgress.java:401)
    at org.apache.hadoop.mapred.JobTracker.submitJob(JobTracker.java:3921)
    ... 11 more

Streaming Job Failed!

How can I resolve this?

Thank you

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

我喜欢麦丽素 2024-12-15 13:41:37

需要正确配置mapred.local.dir。检查是否在mapred-site或hdfs-site中配置。该目录应该存在。执行作业的用户应该对此目录具有适当的权限

mapred.local.dir need to be configured properly. check whether it is configured in mapred-site or hdfs-site. The directory should be existing. User who executes the job should have proper permission on this directory

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文