Skip to content

Instantly share code, notes, and snippets.

@JensRantil
JensRantil / tombstone-count.sh
Last active March 31, 2021 18:04
How to count number of tombstones per partition key in one or multiple sstables.
#!/bin/bash
#
# Counts number of tombstones per partition key in one or multiple sstables.
#
# Usage: ./tombstone-count.sh /var/lib/cassandra/data/mykeyspace/mytable/*-Data.db
#
# Sample output:
# "40e6a9839bf44bdaa624cc53e96733fe" 8
# "8e177ab222c14f868bcb6d2922b18d2b" 8
# "28aaa9db0dad4ae78cabe8bcc25d14a3" 9