Storage Path in Deployment with HA

23 views
Skip to first unread message

Kavinder Dhaliwal

unread,
Jan 2, 2013, 11:50:22 AM1/2/13
to neo...@googlegroups.com
Hi,

I've just implemented the new neo4j HA feature and am deploying to aws.  Before I would set the storage path to the shared folder that capistrano setup and just set a symlink which worked fine.  Now that the HA creates a new db folder for every access, and also now that HA allows me to scale to multiple instances where should i set my storage path? 

Thanks

Mattias Persson

unread,
Jan 2, 2013, 1:12:55 PM1/2/13
to neo...@googlegroups.com

Each instance needs to have its own exclusive db folder, local to where the neo4j jvm runs.

Did you manage to share one folder with many instances before? That's not supposed to work, and you shouldn't be able to even start the second database instance.

--
You received this message because you are subscribed to the Google Groups "neo4jrb" group.
To view this discussion on the web visit https://groups.google.com/d/msg/neo4jrb/-/LKgq95o3ioYJ.
To post to this group, send email to neo...@googlegroups.com.
To unsubscribe from this group, send email to neo4jrb+u...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/neo4jrb?hl=en.

Andreas Ronge

unread,
Jan 2, 2013, 1:16:04 PM1/2/13
to neo...@googlegroups.com
Hi

Are you talking about using the 'neo4j/rails/ha_console/railtie' and
deploying to AWS ?
The ha-console/railite should only be used as a development tool and
maybe as an example how to configure your own HA Rails Cluster to run
on several different machines, see the impl of it here:
https://github.com/andreasronge/neo4j/blob/master/lib/neo4j/rails/ha_console/railtie.rb

Why don't you always use the same location of the database (e.g. the
same location as you did before) and make sure you only start one
rails instance per machine ?
Notice that you should not deploy more than one Rails HA instance per
machine, since the Java Runtime will use all available cores on the
machines (config.threadsafe!, see
http://jrubytips.com/posts/3-enable-threadsafe-for-rails).

Cheers

Kavinder Dhaliwal

unread,
Jan 2, 2013, 2:33:03 PM1/2/13
to neo...@googlegroups.com
Yeah I'm talking about the railtie. I have no need to really scale to multiple machines, but would like to the ability to access the console on an instance.  So this won't be possible using the railtie?  I should setup another machine just for that purpose? 

The HA cluster is all new to me, sorry for the confusion.

Andreas Ronge

unread,
Jan 2, 2013, 4:01:23 PM1/2/13
to neo...@googlegroups.com
Ok, I guess using HA for debugging and using the console remotely
could be useful.
But you can't use my railtie because you need to set the IP and port
of the remote machine instead of using localhost. You need to
configure the HA properties in your config/application.rb.

My railitie should only be used for development using a single machine
with several Neo4j instances running (e.g. rails, rails console, neo4j
server), each on a different storage_path.
> https://groups.google.com/d/msg/neo4jrb/-/hw2mIPOHWfwJ.

Michael Hunger

unread,
Jan 3, 2013, 6:07:26 AM1/3/13
to neo...@googlegroups.com
If you only want to use the neo4j-commandline-console, you can just enable it with enable_remote_shell=true in your config then a neo4j-shell script invocation connects to the locally running database.
(or provide -host -port for remote servers)

Michael
Reply all
Reply to author
Forward
0 new messages