cassandra-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Oleksandr Shulgin <oleksandr.shul...@zalando.de>
Subject Re: Alter table gc_grace_seconds
Date Wed, 04 Oct 2017 06:39:16 GMT
On Sun, Oct 1, 2017 at 4:14 PM, Gábor Auth <auth.gabor@gmail.com> wrote:

> Hi,
>
> On Sun, Oct 1, 2017 at 3:44 PM Varun Barala <varunbarala99@gmail.com>
> wrote:
>
>> This is the property of table and It's not written in sstables. If you
>> change gc_grace, It'll get applied for all the data.
>>
>
> Hm... I've migrated lot of data from `number_item` to `measurement` CF
> because of scheme upgrade. During the migration, the script created rows in
> the `measurement` CF and deleted the migrated rows in the `number_item` CF,
> one-by-one.
>
> I've just take a look on the sstables of `number_item` and it is full of
> deleted rows:
> {
>   "type" : "row",
>   "position" : 146160,
>   "clustering" : [ "humidity", "97781fd0-9dab-11e7-a3d5-7f6ef9a844c7" ],
>   "deletion_info" : { "marked_deleted" : "2017-09-25T11:51:19.165276Z",
> "local_delete_time" : "2017-09-25T11:51:19Z" },
>   "cells" : [ ]
> }
>
> How can I purge these old rows? :)
>
> I've tried: compact, scrub, cleanup, clearsnapshot, flush and full repair.
>

If you have migrated ALL the data from the old CF, you could just use
TRUNCATE or DROP TABLE, followed by "nodetool clearsnapshot" to reclaim the
disk space (this step has to be done per-node).

--
Alex

Mime
View raw message