标签:nbsp des 默认 clu replicat and local ring factor
cassandra安装配置用cqlsh登录以后,默认集群是Test Cluster,而thingsboard中要求是Thingsboard Cluster
1修改cassandra集群名称
①修改系统中的集群名称
启动cassandra,登录cqlsh,
select cluster_name from system.local;
显示当前cluster是 Test Cluster
UPDATE system.local SET cluster_name = ‘Thingsboard Cluster‘ where key=‘local‘;
验证修改结果
select cluster_name from system.local;
显示结果是Thingsboard Cluster,
退出cqlsh
exit;
②修改配置文件中的集群名称
找到配置文件,apache-cassandra-3.11.3/conf/cassandra.yaml(apache-cassandra-3.11.3是我的当前安装目录)
将cluster_name: ‘Test Cluster‘ 修改为cluster_name: ‘Thingsboard Cluster‘
③将memtable刷为commitlog
在①exit之后,运行
nodetool flush system
重新启动cqlsh,验证
describe cluster;
2创建keyspace:thingsboard
CREATE KEYSPACE thingsboard WITH replication = {‘class‘: ‘SimpleStrategy‘, ‘replication_factor‘: ‘1‘};
验证
describe keyspaces;
标签:nbsp des 默认 clu replicat and local ring factor
原文地址:https://www.cnblogs.com/xfvipp/p/9838247.html