Deletion of data within particular time frame

34 views
Skip to first unread message

HarShvArdHan AmrUtpHalE

unread,
Mar 28, 2018, 3:20:08 AM3/28/18
to OpenTSDB
Hi All,

We have 'tsdb' table of size around 25 TB, we would like to delete/purge data older than 13 months irrespective of the metric name. Could you please suggest command to delete data.

I have checked the URL(http://opentsdb.net/docs/build/html/user_guide/cli/scan.html), I have a couple of question in below command

scan [--delete|--import] START-DATE [END-DATE] query [queries...]

1. START-DATE [END-DATE] can we give it as epoch time?
2. I didn't understand the use of 'query' in above command. As I mentioned above we have to delete data irrespective of metric name so do we have to use this('query').
3. And after this first-time purge/delete can we use TTL in OpenTSDB(table: tsdb) Hbase table, so that in future HBase will auto delete data.

Note: I believe we don't have to delete data from UID table. Correct me if I'm wrong. 

Thanks,
Harshvardhan

John Ewing

unread,
Apr 16, 2018, 8:49:22 AM4/16/18
to OpenTSDB
You can achieve this by using the hbase TTL function to remove rows older than a certain age

Reply all
Reply to author
Forward
0 new messages