Skip to content

Commit

Permalink
ccmlib/node: cleanup unsealed system sstables for offline tools
Browse files Browse the repository at this point in the history
see also 3616251

otherwise, `sstablelevelreset` would try to load the unsealed
sstables and print out error messages in stderr if not all the
components are available or is corrupted. this fails the test
which checks for unexpected errors.

Fixes scylladb/scylladb#15210

Signed-off-by: Kefu Chai <[email protected]>
  • Loading branch information
tchaikov authored and fruch committed Aug 30, 2023
1 parent 48fd2dc commit a45eda9
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions ccmlib/node.py
Original file line number Diff line number Diff line change
Expand Up @@ -1891,8 +1891,10 @@ def __gather_sstables(self, datafiles=None, keyspace=None, columnfamilies=None):
return files

def __cleanup_sstables(self, keyspace, cf):
if keyspace != 'system_schema':
self.get_sstables('system_schema', '', cleanup_unsealed=True)
system_keyspace_names = ['system_schema', 'system']
if keyspace not in system_keyspace_names:
for system_keyspace_name in system_keyspace_names:
self.get_sstables(system_keyspace_name, '', cleanup_unsealed=True)
try:
return self.get_sstables(keyspace, cf, cleanup_unsealed=True)
except common.ArgumentError:
Expand Down

0 comments on commit a45eda9

Please sign in to comment.