Hadoop:java.io.IOException:属性中没有有效的本地目录:mapred.local.dir
当我运行 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 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
需要正确配置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