Reputation: 15810
I'm taking a dump of a cassandra column family and restoring it into another cassandra database.
Is there an easy way to perform a sanity test to check whether the data has been fully restored into the new column family?
I was hoping to count the number of rows -- however, this looks like a crazy-expensive operation in cassandra.
Upvotes: 0
Views: 122
Reputation: 5249
First of all I assume you're using snapshots for your backups, which is the most common way to backup your Cassandra data. Now depending on how you restore saved snapshots, theres two ways to restore them, either by using sstableloader or by truncating and dropping the saved snapshots into the target column family data directory. The second option should always be safe as snapshots are just flushed SSTables, that have been already been fully written and closed by Cassandra. However, to get a better idea on the available data in a CF, theres also nodetool cfstats <column_family>
which will output statistics on your CF that can be used to compare before and after.
Upvotes: 1