HDFS-17099. Fix Null Pointer Exception when stop namesystem in HDFS.(#6034). Contributed by ConfX.
Signed-off-by: Ayush Saxena <ayushsaxena@apache.org> Signed-off-by: He Xiaoqiao <hexiaoqiao@apache.org>
This commit is contained in:
parent
4cb4d5dd08
commit
8d9d58dfc8
@ -1531,10 +1531,10 @@ void stopActiveServices() {
|
|||||||
if (dir != null && getFSImage() != null) {
|
if (dir != null && getFSImage() != null) {
|
||||||
if (getFSImage().editLog != null) {
|
if (getFSImage().editLog != null) {
|
||||||
getFSImage().editLog.close();
|
getFSImage().editLog.close();
|
||||||
|
// Update the fsimage with the last txid that we wrote
|
||||||
|
// so that the tailer starts from the right spot.
|
||||||
|
getFSImage().updateLastAppliedTxIdFromWritten();
|
||||||
}
|
}
|
||||||
// Update the fsimage with the last txid that we wrote
|
|
||||||
// so that the tailer starts from the right spot.
|
|
||||||
getFSImage().updateLastAppliedTxIdFromWritten();
|
|
||||||
}
|
}
|
||||||
if (dir != null) {
|
if (dir != null) {
|
||||||
dir.ezManager.stopReencryptThread();
|
dir.ezManager.stopReencryptThread();
|
||||||
|
Loading…
Reference in New Issue
Block a user