Adar Dembo has submitted this change and it was merged. Change subject: KUDU-1634. TS and master should delete tmp metadata files on startup ......................................................................
KUDU-1634. TS and master should delete tmp metadata files on startup Initially it was suggested that TS should delete tmp files from consensus-meta directory, but these leftovers can appear anywhere where atomic write with WritePBContainerToPath() is being used. For now, it is consensus metadata, block manager's data directory, instance metadata, etc. Also, it happens to Master server as well. Hence, I've decided to deal with it on FsManager level and scan all root paths for tmp files. It may slow startup a little bit, but I don't know any way around it because: a) it can't be done on background as it can remove the real tmp files this way; b) it would be nice to have a separate tmp directory, but it makes rename not atomic this way (because we can - and usually will - have root/wal dirs on different drives). Change-Id: I299e7b22c3f920430ff5d581cf7a507a83eb0101 Reviewed-on: http://gerrit.cloudera.org:8080/5007 Tested-by: Kudu Jenkins Reviewed-by: Adar Dembo <[email protected]> --- M src/kudu/fs/fs_manager-test.cc M src/kudu/fs/fs_manager.cc M src/kudu/fs/fs_manager.h 3 files changed, 154 insertions(+), 6 deletions(-) Approvals: Adar Dembo: Looks good to me, approved Kudu Jenkins: Verified -- To view, visit http://gerrit.cloudera.org:8080/5007 To unsubscribe, visit http://gerrit.cloudera.org:8080/settings Gerrit-MessageType: merged Gerrit-Change-Id: I299e7b22c3f920430ff5d581cf7a507a83eb0101 Gerrit-PatchSet: 6 Gerrit-Project: kudu Gerrit-Branch: master Gerrit-Owner: Maxim Smyatkin <[email protected]> Gerrit-Reviewer: Adar Dembo <[email protected]> Gerrit-Reviewer: Kudu Jenkins Gerrit-Reviewer: Maxim Smyatkin <[email protected]> Gerrit-Reviewer: Todd Lipcon <[email protected]>
