Database Reference
In-Depth Information
Backup and recovery
Backup and recovery is another challenge for distributed systems and Neo4j HA architec-
ture provides various tools and utilities for performing online backup and recovery, which
is in sync with the enterprise's operational needs.
Neo4j provides <$NEO4J_HOME>/bin/neo4j-backup as a command-line utility for
performing the Full and Incremental / hot backups.
The following steps need to be performed to enable backups:
1. Enabling online backup: online_backup_enabled should be enabled in
<$NEO4J_HOME>/conf/neo4j.properties .
2. Full backup: Create a blank directory on the machine where you want to take the
full backup and run the backup tool <$NEO4J_HOME>/bin/neo4j-backup
-host <IP-ADDRESS> -port <PORT#> -to <DIR location on
remote server> .
3. Incremental backup: Run the same command that we used to take full backup and
neo4j-backup will only copy the updates from the last backup. Incremental
backups can fail in case the provided directory does not have valid backup or pre-
vious backup is from the older version of the Neo4j database.
4. Recovering database from backup: Modify the
org.neo4j.server.database.location property in
<$NEO4J_HOME>/conf/neo4j-server.properties and provide the
location of directory where backup is stored and restart your Neo4j server.
Note
Online backup can also be performed programmatically using Java by using
org.neo4j.backup.OnlineBackup.java .
Search WWH ::




Custom Search