Default file locations

The following table lists the default location of the Neo4j files, per type, and distribution.

Table 1. Default file locations
File type Description Linux / macOS / Docker Windows Debian / RPM Neo4j Desktop [1]

Bin

The Neo4j running script and built-in tools, such as, cypher-shell and neo4j-admin.

<neo4j-home>/bin

<neo4j-home>\bin

/usr/bin

From the Open dropdown menu of your Neo4j instance, select Terminal, and navigate to <installation-version>/bin.

Configuration [2]

The Neo4j configuration settings, Log4j configuration settings, and the JMX access credentials.

<neo4j-home>/conf/neo4j.conf
<neo4j-home>/conf/server-logs.xml
<neo4j-home>/conf/user-log.xml

<neo4j-home>\conf\neo4j.conf <neo4j-home>\conf\server-logs.xml
<neo4j-home>\conf\user-log.xml

/etc/neo4j/neo4j.conf /etc/neo4j/server-logs.xml
/etc/neo4j/user-log.xml

From the Open dropdown menu of your Neo4j instance, select Terminal, and navigate to <installation-version>/conf/neo4j.conf.

Data [3]

All data-related content, such as databases, transactions, cluster-state (if applicable), dumps, and cypher script files (from the neo4j-admin database restore command).

<neo4j-home>/data

<neo4j-home>\data

/var/lib/neo4j/data

From the Open dropdown menu of your Neo4j instance, select Terminal, and navigate to <installation-version>/data.

Import

All CSV files that the command LOAD CSV uses as sources to import data in Neo4j.

<neo4j-home>/import

<neo4j-home>\import

/var/lib/neo4j/import

From the Open dropdown menu of your Neo4j instance, select Terminal, and navigate to <installation-version>/import.

Labs [4]

Contains APOC Core.

<neo4j-home>/labs

<neo4j-home>\labs

/var/lib/neo4j/labs

From the Open dropdown menu of your Neo4j instance, select Terminal, and navigate to <installation-version>/labs.

Lib

All Neo4j dependencies.

<neo4j-home>/lib

<neo4j-home>\lib

/usr/share/neo4j/lib

From the Open dropdown menu of your Neo4j instance, select Terminal, and navigate to <installation-version>/lib.

Licenses

For storing license files from Neo4j.

<neo4j-home>/licenses

<neo4j-home>\licenses

/var/lib/neo4j/licenses

From the Open dropdown menu of your Neo4j instance, select Terminal, and navigate to <installation-version>/licences.

Logs

The Neo4j log files.

<neo4j-home>/logs [5]

<neo4j-home>\logs

/var/log/neo4j/ [6]

From the Open dropdown menu of your Neo4j instance, select Terminal, and navigate to <installation-version>/logs.

Metrics

The Neo4j built-in metrics for monitoring the Neo4j DBMS and each individual database.

<neo4j-home>/metrics

<neo4j-home>\metrics

/var/lib/neo4j/metrics

From the Open dropdown menu of your Neo4j instance, select Terminal, and navigate to <installation-version>/metrics.

Plugins

Custom code that extends Neo4j, for example, user-defined procedures, functions, and security plugins.

<neo4j-home>/plugins

<neo4j-home>\plugins

/var/lib/neo4j/plugins

From the Open dropdown menu of your Neo4j instance, select Terminal, and navigate to <installation-version>/plugins.

Products

The jar files of the Neo4j products: Graph Data Science Library and Bloom. The folder also contains a README.txt file with information on enabling them.

<neo4j-home>/products

<neo4j-home>\products

/var/lib/neo4j/products

From the Open dropdown menu of your Neo4j instance, select Terminal, and navigate to <installation-version>/products.

Run

The processes IDs.

<neo4j-home>/run

<neo4j-home>\run

/var/lib/neo4j/run

From the Open dropdown menu of your Neo4j instance, select Terminal, and navigate to <installation-version>/run.

1. Applicable to all operating systems where Neo4j Desktop is supported.

2. For details about neo4j.conf, see: The neo4j.conf file.

3. The data directory is internal to Neo4j and its structure is subject to change between versions without notice.

4. For more information, see APOC User Guide → Installation.

5. To view neo4j.log in Docker, use docker logs <containerID/name>.

6. To view the neo4j.log for Debian and RPM, use journalctl --unit=neo4j.

Customize your file locations

The file locations can also be customized by using environment variables and options.

The locations of <neo4j-home> and conf can be configured using environment variables:

Table 2. Configuration of <neo4j-home> and conf
Location Default Environment variable Notes

<neo4j-home>

parent of bin

NEO4J_HOME

Must be set explicitly if bin is not a subdirectory.

conf

<neo4j-home>/conf

NEO4J_CONF

Must be set explicitly if it is not a subdirectory of <neo4j-home>.

The rest of the locations can be configured by uncommenting the respective setting in the conf/neo4j.conf file and changing the default value.

#server.directories.data=data
#server.directories.plugins=plugins
#server.directories.logs=logs
#server.directories.lib=lib
#server.directories.run=run
#server.directories.licenses=licenses
#server.directories.metrics=metrics
#server.directories.transaction.logs.root=data/transactions
#server.directories.dumps.root=data/dumps

File permissions

The operating system user that Neo4j server runs as must have the following minimal permissions:

Read only
  • conf

  • import

  • bin

  • lib

  • labs

  • plugins

  • products

  • certificates

  • licenses

Read and write
  • data

  • logs

  • metrics

  • run

Execute
  • all files in bin