Cro*_*wie 47 cql cassandra cqlsh
我可以用什么cqlsh命令快速查看集群中的键空间?cqlsh没有提供show keyspaces,describe cluster也没有我想要的简洁.
我正在使用以下规格:
cqlsh 2.2.0,Cassandra 1.1.10,CQL spec 2.0.0,Thrift协议19.33.0
abh*_*bhi 103
非常简单.只需在cqlsh shell中输入此命令即可享受
select * from system.schema_keyspaces;
Run Code Online (Sandbox Code Playgroud)
在C*3.x中,我们可以简单地使用
describe keyspaces
Run Code Online (Sandbox Code Playgroud)
Pet*_*ing 46
试试这个:
describe keyspaces
Run Code Online (Sandbox Code Playgroud)
然而,你可能需要大约以下的规格(而不是提到的那些自己Crowie)
[cqlsh 4.1.1 | Cassandra 2.0.6 | CQL规范3.1.1 | 节俭协议19.39.0]
Gab*_* Wu 10
cqlsh> select * from system_schema.keyspaces;
keyspace_name | durable_writes | replication
--------------------+----------------+-------------------------------------------------------------------------------------
system_auth | True | {'class': 'org.apache.cassandra.locator.SimpleStrategy', 'replication_factor': '1'}
system_schema | True | {'class': 'org.apache.cassandra.locator.LocalStrategy'}
system_distributed | True | {'class': 'org.apache.cassandra.locator.SimpleStrategy', 'replication_factor': '3'}
system | True | {'class': 'org.apache.cassandra.locator.LocalStrategy'}
system_traces | True | {'class': 'org.apache.cassandra.locator.SimpleStrategy', 'replication_factor': '2'}
Run Code Online (Sandbox Code Playgroud)
| 归档时间: |
|
| 查看次数: |
40161 次 |
| 最近记录: |