There's actually not much that's _required_ in core.properties, so if you want to try this just create a core directory by hand under SOLR_HOME and name it by the pattern that other cores use. Then use a core.properties file from another replica in the same collection and substitute every property in the file with the values from the deleted node in ZK. If you put the index in the data dir and restart Solr you should be good to go.
But as Shawn says, there are other issues. WARNING: even a small mis-step have "interesting" results. No, I don't think this is something I think would be good to add to the collections API. Having replicas distributed among the cluster and backup/restore are the supported ways of not winding up in this situation. Having the collections command would be too easy to mis-use. Any reconstructed node would NOT have any data associated with it, so it requires being in a non-standard setup to be useful IMO. Frankly, to cover your situation, why not copy from one level up? I.e. save off "collection1_core1_replica1n"? Assuming you have a leader, ADDREPLICA is also a way to build out your cluster after a failure. Best, Erick On Tue, Apr 10, 2018 at 11:16 AM, Shawn Heisey <apa...@elyograg.org> wrote: > On 4/9/2018 2:28 PM, Karthik Ramachandran wrote: >> We are using Solr cloud with 3 nodes, no replication with 8 shard per node >> per collection. We have multiple collection on that node. >> >> We have backup of data the data folder, so we can recover it, is there a >> way to reconstruct core.properties for all the replica's for that node? > > If the router in use for a multi-shard collection is compositeId, then > the core.properties file does NOT contain all the information necessary > to restore the shard in the collection. Part of the information will > ONLY be in zookeeper. I am thinking specifically the hash range for the > shard. > > I think it might be a good idea to write all information necessary to > fully recreate a shard in a collection to core.properties. Make it > possible to reconstruct a SolrCloud if the zookeeper database is lost. > Store information currently only in ZK, like the router name, shard hash > range, etc. > > Thanks, > Shawn >