Yingchun Lai has posted comments on this change. ( 
http://gerrit.cloudera.org:8080/19357 )

Change subject: [tools] Add 'kudu local_replica edit_metadata delete_rowsets' 
to delete rowsets from tablet
......................................................................


Patch Set 1:

(3 comments)

http://gerrit.cloudera.org:8080/#/c/19357/1//COMMIT_MSG
Commit Message:

http://gerrit.cloudera.org:8080/#/c/19357/1//COMMIT_MSG@7
PS1, Line 7: edit
> nit: How about renaming it to 'edit_metadata'?
Done


http://gerrit.cloudera.org:8080/#/c/19357/1/src/kudu/tablet/tablet_metadata.cc
File src/kudu/tablet/tablet_metadata.cc:

http://gerrit.cloudera.org:8080/#/c/19357/1/src/kudu/tablet/tablet_metadata.cc@71
PS1, Line 71: only rowset ids are removed from "
            :             "tablet metadata, the related blocks are kept on file 
system. You "
            :             "can start the server to check whether the operation 
is worked as "
            :             "expect, if it is, then shutdown the server and run 
'kudu fs check "
            :             "--repair=true' to remove orphaned blocks, or use the 
backup "
            :             "tablet-metadata to roll back.
> I'm curious about the scene where we need to keep blocks in this way. From
Without the flag, the rowset blocks will be added to orphaned_blocks_ (by 
AddOrphanedBlocksUnlocked, in line 693), the follow up Flush will delete the 
blocks from fs_manager (line 592), so even if we can use the backup metadata to 
try to roll back, the blocks have been removed. Then some errors will report 
when restart server.
Failed to open rowset RowSet(0): Not found: Can't find block: 0000000000000036


http://gerrit.cloudera.org:8080/#/c/19357/1/src/kudu/tools/kudu-tool-test.cc
File src/kudu/tools/kudu-tool-test.cc:

http://gerrit.cloudera.org:8080/#/c/19357/1/src/kudu/tools/kudu-tool-test.cc@8812
PS1, Line 8812:   ASSERT_EQ(rowset_ids.size() - 1, new_rowset_ids.size());
> nit: Should we also check that new_rowset_ids do not contain the id of dele
Done



--
To view, visit http://gerrit.cloudera.org:8080/19357
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings

Gerrit-Project: kudu
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: If2cf9035babf4c3af4c238cebe8dcecd2c65848f
Gerrit-Change-Number: 19357
Gerrit-PatchSet: 1
Gerrit-Owner: Yingchun Lai <[email protected]>
Gerrit-Reviewer: Alexey Serbin <[email protected]>
Gerrit-Reviewer: KeDeng <[email protected]>
Gerrit-Reviewer: Kudu Jenkins (120)
Gerrit-Reviewer: Yifan Zhang <[email protected]>
Gerrit-Reviewer: Yingchun Lai <[email protected]>
Gerrit-Reviewer: Yuqi Du <[email protected]>
Gerrit-Comment-Date: Fri, 16 Dec 2022 17:08:04 +0000
Gerrit-HasComments: Yes

Reply via email to