Elasticsearch data directory


(R Heng) #1

Is there a reason why a new directory was created for the elasticsearch data indices.

When elasticsearch was initially installed, it create a path ../data/elasticsearch/../nodes/0

Now i see ../data/elasticsearch/../nodes/1 as well.

My schema got all messed up because now its pointing to ../nodes/1 where the mapping is using the default.

My question is what triggers creating the new directory and is there a way were i can tell it not to create a new directory?


(David Pilato) #2

You started another node from the same dir with same settings.

This will fail in 5.x series now BTW.


(R Heng) #3

oh..so for a clusters, each nodes should have its own name...I think i used the same path..


(R Heng) #4

i meant have its own unique path.


(David Pilato) #5

You should not run more than one node on a physical machine, unless you have more than 64gb of RAM.

That's why it's now blocked by default on elasticsearch 5.0 so you don't run a second node by mistake.


(R Heng) #6

I'm not following..

I currently run elasticsearch on 2 nodes. I get a primary and secondary shard. If i only run elasticsearch on one node, i lose redundancy. I want the redundancy.


(David Pilato) #7

But in your case you ran 2 elasticsearch nodes on one physical machine.
Don't do that and run only one elasticsearch node per physical machine.


(R Heng) #8

hmm...how could i run 2 elasticsearch nodes on one physical machine? I guess thats the part i'm confused about.


(R Heng) #9

how could i prevent multiple elasticsearch nodes on one physical system? Is there a setting that I could set to prevent this?


(David Pilato) #10

5.x has that out of the box. If you are starting a new project, please use that version.
If not, consider upgrading.

On a mobile ATM so can't really tell but I think you have something like max local storage option.


(system) #11

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