【发布时间】:2017-09-13 10:57:55
【问题描述】:
在使用网络拓扑策略插入查询的 elassandra 中,它显示“没有可用的主机”。
cqlsh>CREATE KEYSPACE IF NOT EXISTS twitter WITH replication={ 'class':'NetworkTopologyStrategy', 'dc1':'1' };
cqlsh>CREATE TABLE twitter.user (
name text,
attrs map<text,text>,
PRIMARY KEY (name)
);
cqlsh>INSERT INTO twitter.user (name,attrs) VALUES ('bob',{'email':'bob@gmail.com','firstname':'bob'});
【问题讨论】:
-
显示使用nodetool状态的输出
-
sachin@user-PC:~/elassandraDemo/elassandra-2.4.2/bin$ ./nodetool status twitter 数据中心:DC1 ============== 状态=Up/Down |/ State=Normal/Leaving/Joining/Moving -- 地址加载令牌拥有(有效)主机 ID 机架 UN 127.0.0.1 186.72 KB 8 0.0% 089a9ce4-7676-4b14-9773-58aa5913fa34 r1
标签: elasticsearch cassandra cqlsh elassandra