Neo4j can be installed as a server, running either as a headless application or system service.
Download the latest release from http://neo4j.com/download
Extract the contents of the archive
NEO4J_HOME
Use the scripts in the bin
directory
$NEO4J_HOME/bin/neo4j start
%NEO4J_HOME%\bin\Neo4j.bat
doc
directory for details
With administrative rights, Neo4j can be installed as a Windows service.
%NEO4J_HOME%
bin\Neo4j.bat install
To uninstall, run bin\Neo4j.bat remove
as Administrator.
To query the status of the service, run bin\Neo4j.bat query
To start/stop the service from the command prompt, run bin\Neo4j.bat +action+
Neo4j can participate in the normal system startup and shutdown process. The following procedure should work on most popular Linux distributions:
cd $NEO4J_HOME
sudo ./bin/neo4j install
if asked, enter your password to gain super-user privileges
service neo4j-service status
should indicate that the server is not running
service neo4j-service start
will start the server
During installation you will be given the option to select the user Neo4j will run as. You will be asked to supply a username (defaulting to neo4j
) and if that user is not present on the system it will be created as a system account and the $NEO4J_HOME/data
directory will be chown
'ed to that user.
You are encouraged to create a dedicated user for running the service and for that reason it is suggested that you unpack the distribution package under /opt
or your site specific optional packages directory.
Finally, note that if you chose to create a new user account, on uninstall you will be prompted to remove it from the system.
Neo4j can be installed as a Mac launchd job:
cd $NEO4J_HOME
./bin/neo4j install
launchctl list | grep neo
should reveal the launchd "org.neo4j.server.7474" job for running the Neo4j Server
./bin/neo4j status
should indicate that the server is running
Neo4j can be set up to run as several instances on one machine, providing for instance several databases for development. To configure, install two instances of the Neo4j Server in two different directories. Before running the Windows install or startup, change in conf/neo4j-wrapper.conf
# Name of the service for the first instance wrapper.name=neo4j_1
and for the second instance
# Name of the service for the second instance wrapper.name=neo4j_2
in order not to get name clashes installing and starting the instances as services.
Also, the port numbers for the web administration and the servers should be changed to non-clashing values in conf/neo4j-server.properties:
Server 1 (port 7474):
org.neo4j.server.webserver.port=7474
Server 2 (port 7475):
org.neo4j.server.webserver.port=7475
For information on High Availability, please refer to Chapter 19, High Availability.
Copyright © 2011 Neo Technology