Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Multiple standalone neo4j instances on a single machine

Tags:

neo4j

I was wondering if I could run multiple standalone instances of neo4j on a single machine. I understand that I could configure multiple instances as HA cluster (here), but that is not my intention, I only need two totally different and independent instances of neo4j on my machine (Which is a Mac OSX if that makes a difference). This is only for my dev testing and I tried having two separate directories with different data/ and setting two different ports for them, but only one runs properly.

I would appreciate any help coming my way. Thank you.

like image 749
Mepla Avatar asked Sep 13 '15 10:09

Mepla


2 Answers

You can also run individual docker images which point to different data directories,

see: http://neo4j.com/developer/docker

like image 148
Michael Hunger Avatar answered Sep 28 '22 09:09

Michael Hunger


The most easy way is to unpack the neo4j installation into two different locations. In one of the locations you need to change the port settings in conf/neo4j-server.properties and, if neo4j-shell is enabled conf/neo4j.properties as well.

Also consider to set dbms.pagecache.memory to a reasonable value. By default each instance will eat up up to 75 % of RAM minus heap space - which is too much when running multiple instance on one box.

Based on @mepla's findings: the https port in neo4j-server.properties needs to be changed as well.

like image 22
Stefan Armbruster Avatar answered Sep 28 '22 08:09

Stefan Armbruster