生产环境发现一个分片上的数据为空,为了测试依次执行如下:
/routing_test/data/0?routing=0
{
"name": "0"
}
/routing_test/data/1?routing=1
{
"name": "1"
}
/routing_test/data/2?routing=2
{
"name": "2"
}
/routing_test/data/3?routing=3
{
"name": "3"
}
/routing_test/data/4?routing=4
{
"name": "4"
}
最后执行 _cat/shards/routing_test?v&h=index,shard,prirep,state,docs,store
/routing_test/data/0?routing=0
{
"name": "0"
}
/routing_test/data/1?routing=1
{
"name": "1"
}
/routing_test/data/2?routing=2
{
"name": "2"
}
/routing_test/data/3?routing=3
{
"name": "3"
}
/routing_test/data/4?routing=4
{
"name": "4"
}
最后执行 _cat/shards/routing_test?v&h=index,shard,prirep,state,docs,store
index shard prirep state docs store
routing_test 2 p STARTED 2 5.9kb
routing_test 1 p STARTED 0 130b
routing_test 4 p STARTED 1 3kb
routing_test 3 p STARTED 1 3kb
routing_test 0 p STARTED 1 3kb
为什么分片1上没有数据,而分片2上两条数据呢?
2 个回复
famoss
赞同来自:
lbeny - 数据挖掘、自然语言处理
赞同来自: