【发布时间】:2016-10-07 17:41:09
【问题描述】:
我已经创建了一个这样的 cassandra 表,其中包含大量信息:
CREATE TABLE keyspace.table1 (
uuid blob,
id bigint,
timestamp bigint,
description text,
option1 double,
PRIMARY KEY (uuid, id) ) WITH CLUSTERING ORDER BY (id ASC)
AND bloom_filter_fp_chance = 0.01
AND caching = '{"keys":"ALL", "rows_per_partition":"NONE"}'
AND comment = ''
AND compaction = {'class': 'org.apache.cassandra.db.compaction.SizeTieredCompactionStrategy'}
AND compression = {'sstable_compression': 'org.apache.cassandra.io.compress.LZ4Compressor'}
AND dclocal_read_repair_chance = 0.1
AND default_time_to_live = 0
AND gc_grace_seconds = 864000
AND max_index_interval = 2048
AND memtable_flush_period_in_ms = 0
AND min_index_interval = 128
AND read_repair_chance = 0.0
AND speculative_retry = '99.0PERCENTILE';
我正在尝试对其运行 nodetool cfstats 以确定行数。我在网上搜索,似乎键数(估计)应该是行数。但是,如下所示,这个数字非常低,所以我知道这不可能。我做错了什么?
Table: table1
SSTable count: 3
Space used (live): 195.02 MB
Space used (total): 195.02 MB
Space used by snapshots (total): 567.99 KB
Off heap memory used (total): 61.83 KB
SSTable Compression Ratio: 0.3936987749701019
Number of keys (estimate): 19
Memtable cell count: 612048
Memtable data size: 14.18 MB
Memtable off heap memory used: 0 bytes
Memtable switch count: 6
Local read count: 2657130
Local read latency: 0.055 ms
Local write count: 2409743
Local write latency: 0.017 ms
Pending flushes: 0
Bloom filter false positives: 0
Bloom filter false ratio: 0.00000
Bloom filter space used: 64 bytes
Bloom filter off heap memory used: 40 bytes
Index summary off heap memory used: 84 bytes
Compression metadata off heap memory used: 61.71 KB
Compacted partition minimum bytes: 49.82 KB
Compacted partition maximum bytes: 85.8 MB
Compacted partition mean bytes: 27.06 MB
Average live cells per slice (last five minutes): 1.0160752060827343
Maximum live cells per slice (last five minutes): 5722
Average tombstones per slice (last five minutes): 1.0
Maximum tombstones per slice (last five minutes): 1
如果这不可行,还有其他方法可以获取表格的行数吗?
谢谢
【问题讨论】:
标签: cassandra datastax cassandra-2.0 nosql