-
Notifications
You must be signed in to change notification settings - Fork 15
Backup your imeji instance
The offline imeji backup ist most complete and should be performed on a non-running imeji instance. This procedure will describe only the backup of imeji data (not the Elasticsearch)
- Stop imeji application server (see Install: Stop imeji)
- Copy all files from directories specified in imeji.properties for 'imeji.tdb.path' (Jena TDB data) and 'imeji.storage.path' (actual uploaded files) to your backup location (tar, zip data in the backup location if preferred)
- Start imeji application server (see Install: Start imeji) We also provide a bash script which you may adapt to your needs schedule its execution as preferred. Check our sources on GitHub.
Note: sole backup of the files specified in the 'imeji.storage.path' directory you may perform at any time and there is no need to stop your running imeji instance.
- Stop imeji application server (see Install: Stop imeji)
- Restore files from your backup location to desired new data location * if you restore to the previous locations specified in imeji.properties 'imeji.tdb.path' (Jena TDB data) and 'imeji.storage.path' (actual uploaded files) make sure they are empty before restoring * if your backup has been archived with tar or zip make sure data is properly extracted
- Check if directories specified in 'imeji.tdb.path' and 'imeji.storage.path' have correct values and point to the locations from step 2
- Start the imeji application server (see Install: Start imeji)
- Log in as administrator user (e.g. [email protected]) and reindex the data again by invoking Admin->Storage administration->Tools->Search->Re-index
To backup the application server where imeji runs at best follow the official documentation for the application server. Additionally, make sure you backup your configuration data and properties. Below a very simplified example for Tomcat, procedure may differ depending on your specific installation. Backup i.e. copy to desired backup location all data available in tomcat_home directory. You may exclude following directories:
- tomcat_home/work
- tomcat_home/temp
- tomcat_home/webapps/imeji
- tomcat_home/logs
Note: tomcat_home/webapps/imeji is a directory and it is not necessary to backup, as it is automatically restored during deployment or the application server startup. Do not confuse this with the imeji.war file which is in /tomcat_home/webapps directory - imeji.war file should be preserved.
To restore the Tomcat application server copy the backup to a desired location, remove data from /work and /temp directories and start the imeji instance. If you had any other specific settings elsewhere which points to the tomcat_home and if you changed the tomcat_home, make sure you change those settings accordingly.
TODO
Please refer to the official documentation:
- Elastic search documentation to backup your data (useful when upgrading to newer version)
- Elasticsearch documentation to backup your cluster (useful for complete disaster recovery scenario)
- Restoring data from a snapshot