Caused by: java.io.IOException: Filesystem closed的处理

简介: org.apache.hadoop.hive.ql.metadata.HiveException: Unable to rename output from: hdfs://nameservice/user/hive/warehouse/om_dw.
org.apache.hadoop.hive.ql.metadata.HiveException: Unable to rename output from: hdfs://nameservice/user/hive/warehouse/om_dw.db/mac_wifi_day_data/tid=CYJOY/.hive-staging_hive_2016-01-20_10-19-09_200_1283758166994658237-1/_task_tmp.-ext-10002/c_date=2014-10-06/_tmp.000151_0 to: hdfs://nameservice/user/hive/warehouse/om_dw.db/mac_wifi_day_data/tid=CYJOY/.hive-staging_hive_2016-01-20_10-19-09_200_1283758166994658237-1/_tmp.-ext-10002/c_date=2014-10-06/000151_0
at org.apache.hadoop.hive.ql.exec.FileSinkOperator$FSPaths.commit(FileSinkOperator.java:242)
at org.apache.hadoop.hive.ql.exec.FileSinkOperator$FSPaths.access$200(FileSinkOperator.java:143)
at org.apache.hadoop.hive.ql.exec.FileSinkOperator.closeOp(FileSinkOperator.java:1051)
at org.apache.hadoop.hive.ql.exec.Operator.close(Operator.java:617)
at org.apache.hadoop.hive.ql.exec.Operator.close(Operator.java:631)
at org.apache.hadoop.hive.ql.exec.Operator.close(Operator.java:631)
at org.apache.hadoop.hive.ql.exec.Operator.close(Operator.java:631)
at org.apache.hadoop.hive.ql.exec.mr.ExecMapper.close(ExecMapper.java:192)
at org.apache.hadoop.mapred.MapRunner.run(MapRunner.java:61)
at org.apache.hadoop.mapred.MapTask.runOldMapper(MapTask.java:453)
at org.apache.hadoop.mapred.MapTask.run(MapTask.java:343)
at org.apache.hadoop.mapred.YarnChild$2.run(YarnChild.java:164)
at java.security.AccessController.doPrivileged(Native Method)
at javax.security.auth.Subject.doAs(Subject.java:415)
at org.apache.hadoop.security.UserGroupInformation.doAs(UserGroupInformation.java:1657)
at org.apache.hadoop.mapred.YarnChild.main(YarnChild.java:158)
Caused by: java.io.IOException: Filesystem closed
at org.apache.hadoop.hdfs.DFSClient.checkOpen(DFSClient.java:808)
at org.apache.hadoop.hdfs.DFSClient.getFileInfo(DFSClient.java:2113)
at org.apache.hadoop.hdfs.DistributedFileSystem$22.doCall(DistributedFileSystem.java:1305)
at org.apache.hadoop.hdfs.DistributedFileSystem$22.doCall(DistributedFileSystem.java:1301)
at org.apache.hadoop.fs.FileSystemLinkResolver.resolve(FileSystemLinkResolver.java:81)
at org.apache.hadoop.hdfs.DistributedFileSystem.getFileStatus(DistributedFileSystem.java:1301)
at org.apache.hadoop.fs.FileSystem.exists(FileSystem.java:1424)
at org.apache.hadoop.hive.ql.exec.FileSinkOperator$FSPaths.commit(FileSinkOperator.java:218)
... 15 more


原因:
多个datanode在getFileSystem过程中,由于Configuration一样,会得到同一个FileSystem。如果有一个datanode在使用完关闭连接,其它的datanode在访问就会出现上述异常


解决办法:
在hdfs core-site.xml里把fs.hdfs.impl.disable.cache设置为true

目录
相关文章
|
7月前
|
网络安全
Caused by: org.springframework.web.client.ResourceAccessException: I/O error on POST request for "http://xxxx.svc.cluster.local:8080/xxxx": Connection reset; nested exception is java.net.SocketException: Connection reset 什么原因导致得
Caused by: org.springframework.web.client.ResourceAccessException: I/O error on POST request for "xxxx.svc.cluster.local:8080/xxxx ": Connection reset; nested exception is java.net.SocketException: Connection reset 什么原因导致得
917 0
|
6月前
|
Java API Maven
【异常】Caused by: java.lang.ClassNotFoundException: javax.xml.bind.annotation.XmlType
【异常】Caused by: java.lang.ClassNotFoundException: javax.xml.bind.annotation.XmlType
54 0
|
18天前
|
Java 应用服务中间件 Linux
Caused by: java.lang.UnsatisfiedLinkError: /root/jdk1.7.0_45/jre/lib/amd64/xawt/libmawt.so: libXrend
Caused by: java.lang.UnsatisfiedLinkError: /root/jdk1.7.0_45/jre/lib/amd64/xawt/libmawt.so: libXrend
|
24天前
|
Java 开发工具 计算机视觉
Caused by: java.lang.UnsatisfiedLinkError: Can‘t load AMD 64-bit .dll on a IA 32-bit platform【已解决】
Caused by: java.lang.UnsatisfiedLinkError: Can‘t load AMD 64-bit .dll on a IA 32-bit platform【已解决】
4 0
|
1月前
|
监控 NoSQL Java
Spring Boot集成Redis启动失败【Caused by: java.lang.ClassNotFoundException: org.apache.commons.pool2.impl.G】
Spring Boot集成Redis启动失败【Caused by: java.lang.ClassNotFoundException: org.apache.commons.pool2.impl.G】
|
1月前
|
SpringCloudAlibaba Java Maven
【问题篇】Caused by: java.lang.NoClassDefFoundError: org/springframework/boot/context/properties/
【问题篇】Caused by: java.lang.NoClassDefFoundError: org/springframework/boot/context/properties/
13 2
|
1月前
|
开发工具
933.【开发工具】解决idea:Caused by: java.net.BindException: Add
933.【开发工具】解决idea:Caused by: java.net.BindException: Add
23 2
|
6月前
|
运维 Java 应用服务中间件
【Nginx异常】无法加载响应数据:No data found for resource with given identifier,后端服务报Caused by: java.io.IOExcepti
【Nginx异常】无法加载响应数据:No data found for resource with given identifier,后端服务报Caused by: java.io.IOExcepti
914 0
|
2月前
|
Java 应用服务中间件
Caused by: java.lang.NoClassDefFoundError: org/springframework/web/context/request/async/CallablePro
Caused by: java.lang.NoClassDefFoundError: org/springframework/web/context/request/async/CallablePro 错误处理
62 0
|
3月前
|
NoSQL Linux 网络安全
解决Caused by: java.net.SocketTimeoutException: connect timed out Exception in thread “main“ redis.cli
解决Caused by: java.net.SocketTimeoutException: connect timed out Exception in thread “main“ redis.cli