Restore Sintelix from a Backup
Introduction
You can schedule Sintelix backups and restore backups.
Restoring Sintelix from a Backup is a manual process.
Backup locations
See Backup Sintelix for information about where backups are stored.
Command line
The restore procedure is run using command line.
Useful commands
List command
This command lists all the available restore commands, which are list and restore-db.

List command
java -cp "C:\Program Files (x86)\Sintelix\webapp\WEB-INF\lib\*" com.sintelix.core.backup.restore.BackupRestore list
Result:
Usage: java -cp "WEB-INF/lib/*" com.sintelix.core.backup.restore.BackupRestore <command> [args]
The available commands for execution are listed below.
Main commands:
list List backup snapshots in a backup location
restore-db Restore the entire Sintelix database from a backup snapshot
Usage command: restore-db
The command below describes how to use the restore command.

Restore command
java -cp "C:\Program Files (x86)\Sintelix\webapp\WEB-INF\lib\*" com.sintelix.core.backup.restore.BackupRestore restore-db
Result:
Usage:
Filesystem backup target: java -cp "WEB-INF/lib/*" com.sintelix.core.backup.restore.BackupRestore restore-db [restore location] [backup commit] fs [path to Sintelix backup]
S3 backup target : java -cp "WEB-INF/lib/*" com.sintelix.core.backup.restore.BackupRestore restore-db [restore location] [backup commit] s3 [S3 bucket name] [prefix for Sintelix backup] [AWS region]
[restore location] is a path to a directory on the local machine that the backup should be restored to
This location can contain an existing Sintelix Database that the backup snapshot was originally created from
[backup commit] is one of the commit values listed by the "list" command
If an S3 backup target is being used, credentials will be retrieved automatically from the locations defined in https://docs.aws.amazon.com/sdk-for-java/latest/developer-guide/credentials-chain.html
Restore backup
Follow the steps below to restore a backup.
-
Stop Sintelix if restoring to the same PC.
-
If Java is not available in the path, change the directory to where Sintelix is installed to use the Java provided by Sintelix.
-
Use the list command to find out the backups in a particular backup location.
-
Copy the commit number of the backup you want to restore, eg. 1715662327996.
-
Run the restore command.
cd C:\Program Files (x86)\Sintelix\jre\bin
java -cp "C:\Program Files (x86)\Sintelix\webapp\WEB-INF\lib\*" com.sintelix.core.backup.restore.BackupRestore list fs "C:\Sintelix Backup"
Result:
Commit Timestamp
------------- ---------------
1715662327996 Tue, 14 May 2024 04:52:07.996 Z (2024-05-14T04:52:07.996Z)
java -cp "C:\Program Files (x86)\Sintelix\webapp\WEB-INF\lib\*" com.sintelix.core.backup.restore.BackupRestore restore-db "C:\Sintelix Database" 1715662327996 fs "C:\Sintelix Backup"
Result:
The backup is restored.
C:\Program Files (x86)\Sintelix\jre\bin>java -cp "C:\Program Files (x86)\Sintelix\webapp\WEB-INF\lib\*" com.sintelix.core.backup.restore.BackupRestore restore-db "C:\Sintelix Database" 1715662327996 fs "C:\Sintelix Backup"
Restoring commit 1715662327996
from "C:\Sintelix Backup"
to "C:\Sintelix Database"
10:33:20.959 [main] INFO com.sintelix.core.backup.restore.RestoreTask - Start restore
10:33:28.638 [main] INFO com.sintelix.core.backup.restore.RestoreTask - Restore completed (7661ms)