NameNode日志中頻繁出現(xiàn)rename失敗的日志器瘪,且頻繁GC
2019-10-22 12:18:15,826 WARN hdfs.StateChange (FSDirRenameOp.java:validateRenameSource(559)) - DIR* FSDirectory.unprotectedRenameTo: rename source /apps/hive/warehouse/zs_db.db/umetrip_client_all/.hive-staging_hive_2019-10-21_15-05-03_662_6055882197773119796-53816/-ext-10000/000080_0 is not found.
2019-10-22 12:18:15,827 WARN hdfs.StateChange (FSDirRenameOp.java:validateRenameSource(559)) - DIR* FSDirectory.unprotectedRenameTo: rename source /apps/hive/warehouse/zs_db.db/umetrip_client_all/.hive-staging_hive_2019-10-21_15-05-03_662_6055882197773119796-53816/-ext-10000/000080_0 is not found.
2019-10-22 12:18:15,827 WARN hdfs.StateChange (FSDirRenameOp.java:validateRenameSource(559)) - DIR* FSDirectory.unprotectedRenameTo: rename source /apps/hive/warehouse/zs_db.db/umetrip_client_all/.hive-staging_hive_2019-10-21_15-05-03_662_6055882197773119796-53816/-ext-10000/000080_0 is not found.
2019-10-22 12:18:15,828 WARN hdfs.StateChange (FSDirRenameOp.java:validateRenameSource(559)) - DIR* FSDirectory.unprotectedRenameTo: rename source /apps/hive/warehouse/zs_db.db/umetrip_client_all/.hive-staging_hive_2019-10-21_15-05-03_662_6055882197773119796-53816/-ext-10000/000080_0 is not found.
2019-10-22 12:18:15,828 WARN hdfs.StateChange (FSDirRenameOp.java:validateRenameSource(559)) - DIR* FSDirectory.unprotectedRenameTo: rename source /apps/hive/warehouse/zs_db.db/umetrip_client_all/.hive-staging_hive_2019-10-21_15-05-03_662_6055882197773119796-53816/-ext-10000/000080_0 is not found.
根據(jù)日志發(fā)現(xiàn)查嘗試rename 文件/apps/hive/warehouse/zs_db.db/umetrip_client_all/.hive-staging_hive_2019-10-21_15-05-03_662_6055882197773119796-53816/-ext-10000/000080_0 楚昭,但該文件并不存在见芹。
根據(jù)路徑懷疑是Hive任務(wù)操作笔呀,但集群中并無運(yùn)行中的Hive任務(wù)封孙。類似
https://issues.apache.org/jira/browse/HIVE-7273已慢。
解決方法:
創(chuàng)建文件/apps/hive/warehouse/zs_db.db/umetrip_client_all/.hive-staging_hive_2019-10-21_15-05-03_662_6055882197773119796-53816/-ext-10000/000080_0
創(chuàng)建該文件后逾礁,NameNode中相關(guān)日志消失苞尝,且GC頻率恢復(fù)正常畸肆。
/apps/hive/warehouse/zs_db.db/umetrip_client_all/ 目錄下多出了文件000080_0_copy_131756330
drwxr-xr-x - umecron hadoop 0 2019-10-22 19:19 /apps/hive/warehouse/zs_db.db/umetrip_client_all/.hive-staging_hive_2019-10-21_15-05-03_662_6055882197773119796-53816
-rw-r--r-- 3 umecron hadoop 0 2019-10-22 19:21 /apps/hive/warehouse/zs_db.db/umetrip_client_all/000080_0_copy_131756330
可能原因是運(yùn)行在Yarn集群中的Hive任務(wù)中的Reducer線程遺留了下來,該線程卡死在嘗試重命名不存在的文件宙址。手工創(chuàng)建該文件后轴脐,重名成功,遺留線程執(zhí)行結(jié)束抡砂。