I have many closed indices to migrate.But I do not want to open them,then use node tag attribute to migrate them dynamicly.
[root@test ~]# curl -s 'localhost:9200/my_index/_settings?pretty'
{
"my_index" : {
"settings" : {
"index" : {
"routing" : {
"allocation" : {
"require" : {
"tag" : "new"
}
}
},
"number_of_shards" : "8",
"provided_name" : "my_index",
"creation_date" : "1554289841101",
"number_of_replicas" : "0",
"uuid" : "h-czpwf0S9y5re8XYWHWtA",
"version" : {
"created" : "6030299"
}
}
}
}
}
I can get the uuid of the closed index by above command,and I found the 8 shards are staying several old es nodes.
Can i directly rsync the /path.data/nodes/0/indices/h-czpwf0S9y5re8XYWHWtA/
files to the same directory on the new es nodes(it looks like forcing to rebalance the shards )?
I know this operation will make the shards meta data missing.But is it possiblely to use the moved file recovery directly?