I have a 4 nodes & 5 shards Elastic Search (0.90.3) cluster. On restart, I see 4 of 5 shards unassigned and cluster status is red. So I am assuming the way it was restarted was not right. Each node was issued a kill (SIGKILL) command in 30 seconds interval. Meaning some node was killed, 30 seconds later some other node from the remaining 3 was killed & so on.
I tried this solution to have shards reassigned but nothing worked until I manual assigned a primary shard to the cluster using this approach. But manual assigning of primary shard resets the data for the shard resulting in loss.
How do I avoid getting into the unassigned shard problem? And If I am stuck with that problem what is the way to recover without data loss?