Skip to main content

Back up and restore

Back up​

./backup.sh

Neo4j Community dumps its database offline: the script stops Neo4j, writes backups/neo4j.dump with a dated copy beside it, and starts Neo4j again, also when the dump fails. Runs that start or end while Neo4j is stopped are not recorded and log errors, so run it when no runs are expected. A small graph takes seconds.

Copy the files in backups/ somewhere else: they are only a backup once they are off this machine.

Restore​

./restore.sh backups/neo4j-20261024-020000.dump   # or no argument for the latest

This replaces the graph with the one in the dump. The script stops Neo4j, loads the dump and starts Neo4j again.

Removing old runs​

Every run adds to the graph, and nothing removes old runs. Apache Hop 2.20 can delete old executions; until you schedule that, watch the size of the graph and of its backups.