Add new storage for elasticsearch


I need some help on Elasticsearch and adding another storage device in Elastic. The thing is: I have a server running Elasticsearch, Logstash and Kibana. But Elasticsearch data path is running on a disk with only 30gb. I have another disk on that same server for 500gb, but it is not being used...

Does anyone know how to add this device and start indexing on it, and not on the other disk of 30gb?7

Thanks! I really need some help and guidance on this!!

If you can tolerate the downtime, the simplest approach is to shut down Elasticsearch, move the data folder onto the larger disk, adjust the setting in elasticsearch.yml and then start the node back up again.

If you need to do this without downtime then you can start up a second node configured to use the new disk and then use shard allocation filtering to evict the shards from the node that uses smaller disk. Once all the shards are moved over you can retire the old node. Be aware that this doesn't completely work because you have to increase discovery.zen.minimum_master_nodes from 1 to 2 while there are two nodes in the cluster, and then reduce it to 1 again, and you will see warnings that it's not set correctly at some points in the process.

I should add that you should take a backup (snapshot) before doing any of this.


This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.