Summary: information about backing up the persistence databases used by Console (front-end) and all Nodes. 

This documentation is valid only for Console 1.x.

Introduction

Console (front-end) and all Nodes use a persistence database (h2) to store information about global and application level settings. These databases are located by default here:

%PROGRAMDATA%\AipConsole\AipConsole\db > Console front-end
%PROGRAMDATA%\AipConsole\AipNode\db > Node

Automatic backup

By default in ≥ 1.24, these databases are backed up automatically to the following locations at 1am on a nightly basis. For Nodes, the location is determined by storage folder settings - see Configure AIP Node storage folder locations - optional - v. 1.x for more information. 

%PROGRAMDATA%\AipConsole\AipConsole\backup\h2\YYYY-MM-DD_HH-mm-SS.zip > Console front-end
%PROGRAMDATA%\AipConsole\AipNode\backup\\h2\YYYY-MM-DD_HH-mm-SS.zip > Node

Changing the automatic backup strategy

If you want to change how the automatic backup strategy functions, modify the following files:

%PROGRAMDATA%\AipConsole\AipConsole\aipConsole.properties > Console front-end
%PROGRAMDATA%\AipConsole\AipNode\aip-node-app.properties > Node

Locate the following section and make changes as required. Save the file and restart Console/Node to ensure the change is taken into account.

# enable the automatic backup of H2 db
h2.backup.enabled=true
# location to store the backup file
h2.backup.location=C:/CAST/CONSOLE_126/data/AipNode/backup/h2
# scheduled H2 backup every day at 1 am.
h2.backup.cron=0 0 1 * * *
# enable the automatic backup cleanup of H2 db
h2.backup.cleanup.enabled=false
# enable the automatic backup cleanup of H2 db older than x days
h2.backup.cleanup.days=30
h2.backup.enabledSet to true by default. Change to false to disable the automatic h2 backup.
h2.backup.location

Defines the location of the h2 backup file. The path must conform to the following syntax:

Path typeRequired syntaxExamples
UNC network pathBack slashes escaped with a back slash.\\\\server\\some\\path
Local pathForward slashes, not escaped, or back slashes escaped with a back slash.

D:/CAST/some/path

D:\\CAST\\some\\path

Mapped drive

Forward slashes, not escaped, or back slashes escaped with a back slash.

S:/some/path

S:\\some\\path

h2.backup.cron

Governs when the automatic h2 backup is run. Modify any of the six parameters that are listed in this order:

  • seconds (0-59)
  • minutes (0-59)
  • hours (0-23)
  • date of the month (1-31)
  • month (1-12 or JAN-DEC)
  • days of the week (0-6 where Sunday=0 or 7, or SUN, MON, TUE, WED, THU, FRI, SAT, or range of days MON-FRI)

For example to change to running the job at 1am on a Sunday (weekly):

h2.backup.cron==0 0 1 * * SUN
h2.backup.cleanup.enabledSet to false by default. Change to true to enable a backup cleanup process to run when the automatic h2 backup runs. This will remove old backups over a certain age (days) as configured with the h2.backup.cleanup.days option. 
h2.backup.cleanup.daysSet to 30 (days) by default. If the h2.backup.cleanup.enabled option is set to true, any backups over 30 days old will be removed the next time the automatic h2 backup is run. Change the value to change the age threshold for backups before they are removed.