Bug: nodetool snapshot not copying .TOC file for a sstable
Status: Open
Priority: Normal
Created: 16/Dec/21 07:34

In apache cassandra 4.0, I am seeing that nodetool snapshot is not copying the TOC file for one of the sstable. The one difference with this sstable is that time stamp of the TOC file for the problematic sstable is 13 min past rest of the files. 

-rw-rw-r-- 2 cassandra4 cassandra4   47 Dec 15 16:32 /home/cassandra4/apache-cassandra-4.0.1/data/data/nishant/employee-932e34204cf511ecad596bbf203e140e/nb-3-big-CompressionInfo.db
-rw-rw-r-- 2 cassandra4 cassandra4   64 Dec 15 16:32 /home/cassandra4/apache-cassandra-4.0.1/data/data/nishant/employee-932e34204cf511ecad596bbf203e140e/nb-3-big-Data.db
-rw-rw-r-- 2 cassandra4 cassandra4   10 Dec 15 16:32 /home/cassandra4/apache-cassandra-4.0.1/data/data/nishant/employee-932e34204cf511ecad596bbf203e140e/nb-3-big-Digest.crc32
-rw-rw-r-- 2 cassandra4 cassandra4   16 Dec 15 16:32 /home/cassandra4/apache-cassandra-4.0.1/data/data/nishant/employee-932e34204cf511ecad596bbf203e140e/nb-3-big-Filter.db
-rw-rw-r-- 2 cassandra4 cassandra4   16 Dec 15 16:32 /home/cassandra4/apache-cassandra-4.0.1/data/data/nishant/employee-932e34204cf511ecad596bbf203e140e/nb-3-big-Index.db
-rw-rw-r-- 2 cassandra4 cassandra4 4763 Dec 15 16:32 /home/cassandra4/apache-cassandra-4.0.1/data/data/nishant/employee-932e34204cf511ecad596bbf203e140e/nb-3-big-Statistics.db
-rw-rw-r-- 2 cassandra4 cassandra4   56 Dec 15 16:32 /home/cassandra4/apache-cassandra-4.0.1/data/data/nishant/employee-932e34204cf511ecad596bbf203e140e/nb-3-big-Summary.db
*-rw-rw-r-- 1 cassandra4 cassandra4   92 Dec 15 16:45 /home/cassandra4/apache-cassandra-4.0.1/data/data/nishant/employee-932e34204cf511ecad596bbf203e140e/nb-3-big-TOC.txt*

After taking the snapshot with command "~/apache-cassandra-4.0.1/bin/nodetool snapshot -t exp_cas4_new nishant", the content of this sstable snapshot is as follows:

-rw-rw-r-- 2 cassandra4 cassandra4   47 Dec 15 16:32 /home/cassandra4/apache-cassandra-4.0.1/data/data/nishant/employee-932e34204cf511ecad596bbf203e140e/snapshots/exp_cas4_new/nb-3-big-CompressionInfo.db
-rw-rw-r-- 2 cassandra4 cassandra4   64 Dec 15 16:32 /home/cassandra4/apache-cassandra-4.0.1/data/data/nishant/employee-932e34204cf511ecad596bbf203e140e/snapshots/exp_cas4_new/nb-3-big-Data.db
-rw-rw-r-- 2 cassandra4 cassandra4   10 Dec 15 16:32 /home/cassandra4/apache-cassandra-4.0.1/data/data/nishant/employee-932e34204cf511ecad596bbf203e140e/snapshots/exp_cas4_new/nb-3-big-Digest.crc32
-rw-rw-r-- 2 cassandra4 cassandra4   16 Dec 15 16:32 /home/cassandra4/apache-cassandra-4.0.1/data/data/nishant/employee-932e34204cf511ecad596bbf203e140e/snapshots/exp_cas4_new/nb-3-big-Filter.db
-rw-rw-r-- 2 cassandra4 cassandra4   16 Dec 15 16:32 /home/cassandra4/apache-cassandra-4.0.1/data/data/nishant/employee-932e34204cf511ecad596bbf203e140e/snapshots/exp_cas4_new/nb-3-big-Index.db
-rw-rw-r-- 2 cassandra4 cassandra4 4763 Dec 15 16:32 /home/cassandra4/apache-cassandra-4.0.1/data/data/nishant/employee-932e34204cf511ecad596bbf203e140e/snapshots/exp_cas4_new/nb-3-big-Statistics.db
-rw-rw-r-- 2 cassandra4 cassandra4   56 Dec 15 16:32 /home/cassandra4/apache-cassandra-4.0.1/data/data/nishant/employee-932e34204cf511ecad596bbf203e140e/snapshots/exp_cas4_new/nb-3-big-Summary.db

All the other sstables have their TOC files present.