HBASE-14391 Empty regionserver WAL will never be deleted although the coresponding regionserver has been stale (Qianxi Zhang)
This commit is contained in:
parent
54e8c4bf23
commit
8765ffb0ca
|
@ -251,6 +251,10 @@ public class MasterFileSystem {
|
|||
FileStatus[] curLogFiles = FSUtils.listStatus(this.fs, status.getPath(), null);
|
||||
if (curLogFiles == null || curLogFiles.length == 0) {
|
||||
// Empty log folder. No recovery needed
|
||||
// Just delete the directory
|
||||
if (!fs.delete(status.getPath(), false)) {
|
||||
LOG.warn("Unable to delete " + status.getPath());
|
||||
}
|
||||
continue;
|
||||
}
|
||||
final ServerName serverName = DefaultWALProvider.getServerNameFromWALDirectoryName(
|
||||
|
|
Loading…
Reference in New Issue