You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@cassandra.apache.org by Alain RODRIGUEZ <ar...@gmail.com> on 2012/11/14 11:39:09 UTC
Enable compression Cassandra 1.1.2
Hi, I am running C* 1.1.2 and there is no way to turn the compression on
for a CF.
Here is the command I ran in the CLI:
UPDATE COLUMN FAMILY data_action WITH
compression_options={sstable_compression:SnappyCompressor, chunk_length_kb
: 64};
Show schema :
create column family data_action
with column_type = 'Standard'
and comparator = 'UTF8Type'
and default_validation_class = 'UTF8Type'
and key_validation_class = 'UTF8Type'
and read_repair_chance = 1.0
and dclocal_read_repair_chance = 0.0
and gc_grace = 864000
and min_compaction_threshold = 4
and max_compaction_threshold = 32
and replicate_on_write = true
and compaction_strategy =
'org.apache.cassandra.db.compaction.SizeTieredCompactionStrategy'
and caching = 'KEYS_ONLY';
I tried also through cqlsh without success ("ALTER TABLE data_action WITH
compression_parameters:sstable_compression = 'SnappyCompressor' AND
compression_parameters:chunk_length_kb = 64;")
I have no error message just these few lines on system.log:
INFO 10:17:12,051 Completed flushing
/raid0/cassandra/data/system/schema_columnfamilies/system-schema_columnfamilies-hd-20-Data.db
(1367 bytes) for commitlog position
ReplayPosition(segmentId=721932060965088, position=116556860)
INFO 10:17:12,052 Compacting
[SSTableReader(path='/raid0/cassandra/data/system/schema_columnfamilies/system-schema_columnfamilies-hd-20-Data.db'),
SSTableReader(path='/raid0/cassandra/data/system/schema_columnfamilies/system-schema_columnfamilies-hd-19-Data.db'),
SSTableReader(path='/raid0/cassandra/data/system/schema_columnfamilies/system-schema_columnfamilies-hd-17-Data.db'),
SSTableReader(path='/raid0/cassandra/data/system/schema_columnfamilies/system-schema_columnfamilies-hd-18-Data.db')]
INFO 10:17:12,134 Compacted to
[/raid0/cassandra/data/system/schema_columnfamilies/system-schema_columnfamilies-hd-21-Data.db,].
50,928 to 46,827 (~91% of original) bytes for 3 keys at 0.544606MB/s.
Time: 82ms.
I also tried upgrading sstables but compression is definitely not enabled
(same size of data + JMX show a CompressionRatio of 0.0).
Does anyone already saw something similar ?
Alain
Re: Enable compression Cassandra 1.1.2
Posted by Alain RODRIGUEZ <ar...@gmail.com>.
We just upgrade to C* 1.1.6
We can now change anything using the CLI or cqlsh. So problem solved.
2012/11/14 Alain RODRIGUEZ <ar...@gmail.com>
> Oh! That's obviously the exact same issue. I didn't find this thread while
> searching about my issue.
>
> We will upgrade.
>
> Thanks for the link.
>
>
> 2012/11/14 aaron morton <aa...@thelastpickle.com>
>
>> May be https://issues.apache.org/jira/browse/CASSANDRA-4561
>>
>> Can you upgrade to 1.1.6 ?
>>
>> Cheers
>>
>> -----------------
>> Aaron Morton
>> Freelance Cassandra Developer
>> New Zealand
>>
>> @aaronmorton
>> http://www.thelastpickle.com
>>
>> On 14/11/2012, at 11:39 PM, Alain RODRIGUEZ <ar...@gmail.com> wrote:
>>
>> Hi, I am running C* 1.1.2 and there is no way to turn the compression on
>> for a CF.
>>
>> Here is the command I ran in the CLI:
>>
>> UPDATE COLUMN FAMILY data_action WITH
>> compression_options={sstable_compression:SnappyCompressor, chunk_length_kb
>> : 64};
>>
>> Show schema :
>>
>> create column family data_action
>> with column_type = 'Standard'
>> and comparator = 'UTF8Type'
>> and default_validation_class = 'UTF8Type'
>> and key_validation_class = 'UTF8Type'
>> and read_repair_chance = 1.0
>> and dclocal_read_repair_chance = 0.0
>> and gc_grace = 864000
>> and min_compaction_threshold = 4
>> and max_compaction_threshold = 32
>> and replicate_on_write = true
>> and compaction_strategy =
>> 'org.apache.cassandra.db.compaction.SizeTieredCompactionStrategy'
>> and caching = 'KEYS_ONLY';
>>
>> I tried also through cqlsh without success ("ALTER TABLE data_action WITH
>> compression_parameters:sstable_compression = 'SnappyCompressor' AND
>> compression_parameters:chunk_length_kb = 64;")
>>
>> I have no error message just these few lines on system.log:
>>
>> INFO 10:17:12,051 Completed flushing
>> /raid0/cassandra/data/system/schema_columnfamilies/system-schema_columnfamilies-hd-20-Data.db
>> (1367 bytes) for commitlog position
>> ReplayPosition(segmentId=721932060965088, position=116556860)
>> INFO 10:17:12,052 Compacting
>> [SSTableReader(path='/raid0/cassandra/data/system/schema_columnfamilies/system-schema_columnfamilies-hd-20-Data.db'),
>> SSTableReader(path='/raid0/cassandra/data/system/schema_columnfamilies/system-schema_columnfamilies-hd-19-Data.db'),
>> SSTableReader(path='/raid0/cassandra/data/system/schema_columnfamilies/system-schema_columnfamilies-hd-17-Data.db'),
>> SSTableReader(path='/raid0/cassandra/data/system/schema_columnfamilies/system-schema_columnfamilies-hd-18-Data.db')]
>> INFO 10:17:12,134 Compacted to
>> [/raid0/cassandra/data/system/schema_columnfamilies/system-schema_columnfamilies-hd-21-Data.db,].
>> 50,928 to 46,827 (~91% of original) bytes for 3 keys at 0.544606MB/s.
>> Time: 82ms.
>>
>> I also tried upgrading sstables but compression is definitely not enabled
>> (same size of data + JMX show a CompressionRatio of 0.0).
>>
>> Does anyone already saw something similar ?
>>
>> Alain
>>
>>
>>
>
Re: Enable compression Cassandra 1.1.2
Posted by Alain RODRIGUEZ <ar...@gmail.com>.
Oh! That's obviously the exact same issue. I didn't find this thread while
searching about my issue.
We will upgrade.
Thanks for the link.
2012/11/14 aaron morton <aa...@thelastpickle.com>
> May be https://issues.apache.org/jira/browse/CASSANDRA-4561
>
> Can you upgrade to 1.1.6 ?
>
> Cheers
>
> -----------------
> Aaron Morton
> Freelance Cassandra Developer
> New Zealand
>
> @aaronmorton
> http://www.thelastpickle.com
>
> On 14/11/2012, at 11:39 PM, Alain RODRIGUEZ <ar...@gmail.com> wrote:
>
> Hi, I am running C* 1.1.2 and there is no way to turn the compression on
> for a CF.
>
> Here is the command I ran in the CLI:
>
> UPDATE COLUMN FAMILY data_action WITH
> compression_options={sstable_compression:SnappyCompressor, chunk_length_kb
> : 64};
>
> Show schema :
>
> create column family data_action
> with column_type = 'Standard'
> and comparator = 'UTF8Type'
> and default_validation_class = 'UTF8Type'
> and key_validation_class = 'UTF8Type'
> and read_repair_chance = 1.0
> and dclocal_read_repair_chance = 0.0
> and gc_grace = 864000
> and min_compaction_threshold = 4
> and max_compaction_threshold = 32
> and replicate_on_write = true
> and compaction_strategy =
> 'org.apache.cassandra.db.compaction.SizeTieredCompactionStrategy'
> and caching = 'KEYS_ONLY';
>
> I tried also through cqlsh without success ("ALTER TABLE data_action WITH
> compression_parameters:sstable_compression = 'SnappyCompressor' AND
> compression_parameters:chunk_length_kb = 64;")
>
> I have no error message just these few lines on system.log:
>
> INFO 10:17:12,051 Completed flushing
> /raid0/cassandra/data/system/schema_columnfamilies/system-schema_columnfamilies-hd-20-Data.db
> (1367 bytes) for commitlog position
> ReplayPosition(segmentId=721932060965088, position=116556860)
> INFO 10:17:12,052 Compacting
> [SSTableReader(path='/raid0/cassandra/data/system/schema_columnfamilies/system-schema_columnfamilies-hd-20-Data.db'),
> SSTableReader(path='/raid0/cassandra/data/system/schema_columnfamilies/system-schema_columnfamilies-hd-19-Data.db'),
> SSTableReader(path='/raid0/cassandra/data/system/schema_columnfamilies/system-schema_columnfamilies-hd-17-Data.db'),
> SSTableReader(path='/raid0/cassandra/data/system/schema_columnfamilies/system-schema_columnfamilies-hd-18-Data.db')]
> INFO 10:17:12,134 Compacted to
> [/raid0/cassandra/data/system/schema_columnfamilies/system-schema_columnfamilies-hd-21-Data.db,].
> 50,928 to 46,827 (~91% of original) bytes for 3 keys at 0.544606MB/s.
> Time: 82ms.
>
> I also tried upgrading sstables but compression is definitely not enabled
> (same size of data + JMX show a CompressionRatio of 0.0).
>
> Does anyone already saw something similar ?
>
> Alain
>
>
>
Re: Enable compression Cassandra 1.1.2
Posted by aaron morton <aa...@thelastpickle.com>.
May be https://issues.apache.org/jira/browse/CASSANDRA-4561
Can you upgrade to 1.1.6 ?
Cheers
-----------------
Aaron Morton
Freelance Cassandra Developer
New Zealand
@aaronmorton
http://www.thelastpickle.com
On 14/11/2012, at 11:39 PM, Alain RODRIGUEZ <ar...@gmail.com> wrote:
> Hi, I am running C* 1.1.2 and there is no way to turn the compression on for a CF.
>
> Here is the command I ran in the CLI:
>
> UPDATE COLUMN FAMILY data_action WITH compression_options={sstable_compression:SnappyCompressor, chunk_length_kb : 64};
>
> Show schema :
>
> create column family data_action
> with column_type = 'Standard'
> and comparator = 'UTF8Type'
> and default_validation_class = 'UTF8Type'
> and key_validation_class = 'UTF8Type'
> and read_repair_chance = 1.0
> and dclocal_read_repair_chance = 0.0
> and gc_grace = 864000
> and min_compaction_threshold = 4
> and max_compaction_threshold = 32
> and replicate_on_write = true
> and compaction_strategy = 'org.apache.cassandra.db.compaction.SizeTieredCompactionStrategy'
> and caching = 'KEYS_ONLY';
>
> I tried also through cqlsh without success ("ALTER TABLE data_action WITH compression_parameters:sstable_compression = 'SnappyCompressor' AND compression_parameters:chunk_length_kb = 64;")
>
> I have no error message just these few lines on system.log:
>
> INFO 10:17:12,051 Completed flushing /raid0/cassandra/data/system/schema_columnfamilies/system-schema_columnfamilies-hd-20-Data.db (1367 bytes) for commitlog position ReplayPosition(segmentId=721932060965088, position=116556860)
> INFO 10:17:12,052 Compacting [SSTableReader(path='/raid0/cassandra/data/system/schema_columnfamilies/system-schema_columnfamilies-hd-20-Data.db'), SSTableReader(path='/raid0/cassandra/data/system/schema_columnfamilies/system-schema_columnfamilies-hd-19-Data.db'), SSTableReader(path='/raid0/cassandra/data/system/schema_columnfamilies/system-schema_columnfamilies-hd-17-Data.db'), SSTableReader(path='/raid0/cassandra/data/system/schema_columnfamilies/system-schema_columnfamilies-hd-18-Data.db')]
> INFO 10:17:12,134 Compacted to [/raid0/cassandra/data/system/schema_columnfamilies/system-schema_columnfamilies-hd-21-Data.db,]. 50,928 to 46,827 (~91% of original) bytes for 3 keys at 0.544606MB/s. Time: 82ms.
>
> I also tried upgrading sstables but compression is definitely not enabled (same size of data + JMX show a CompressionRatio of 0.0).
>
> Does anyone already saw something similar ?
>
> Alain