0
votes

Currently, I am bench marking Cassandra database using YCSB framework. During this time I have performed (batch) insertion and deletion of the data quite regularly. I am using Truncate command to delete keyspace rows. However, I am noticing that my Cassandra data directory swells up as the experiments.

I have checked and can confirm that even there is no data in the keystore when I checked the size of data directory. Is there a way to initialize a process so that Cassandra automatically release the stored space, or does it happen over time.

1

1 Answers

0
votes

When you use Truncate cassandra will create snapshots of your data.

To disable it you will have to set auto_snapshot: false in cassandra.yaml file.

If you are using Delete, then cassandra use tombstone,i.e your data will not get deleted immediately. Data will get deleted once compaction is ran.

To remove previous snapshots one can use nodetool snapshot command.