Elasticsearch - how to change data path preserving all the data?

33 Views Asked by At

I have read through Elasticsearch documentation and did not find a guide on this. The documentation is a large volume so maybe I simply missed the right chapter and did not manage to find it using on-site nor 3rd part search engines search. Found only some discussions not exactly reflecting my case.

Current data storage dedicated to Elasticsearch indices and other data is almost full. I have prepared another storage and would like to move all the indices and other data there.

What I found in Elasticsearch discussion forum is a sequence of steps like:

  1. BACKUP - make sure you have an Elasticsearch snapshot at the bare minimum
  2. shutdown your Elasticsearch processes
  3. attach new LUN
  4. copy the old Elasticsearch data directory to the new location
  5. remove the old LUN
  6. mount the new LUN to the same location as the old one, so that Elasticsearch sees the same data, just with more space
  7. start your Elasticsearch processes

https://discuss.elastic.co/t/moving-elasticsearch-data-to-new-storage/306658

First, I do not understand what LUN is. And the procedure requires data location to be the same before and after changing storage. In my case I cannot make it this way. Is there a way to make Elasticsearch reuse the data preserved as per 1-4 but using another location/mount?

I understand that I need to ensure I have latest snapshots taken and stored reliably as per

https://www.elastic.co/guide/en/elasticsearch/reference/7.12/snapshot-restore.html

But I am not sure how to change data path and move old data there / or perhaps restore it from the latest snapshot reliably.

0

There are 0 best solutions below