Database Options

NAKIVO Backup & Replication allows you to migrate the internal H2 database used by the NAKIVO Backup & Replication Director to an external database. To do that, take the following steps:

Important

  • If you migrate the internal H2 database to an external database, you will not be able to switch back to the internal database or an external database of the same type later.

  • For multi-tenant mode, only the Master Admin can perform database migration. The functionality is not available for the local tenant. The remote tenant can still perform database migration as described below if they log in as single tenant into NAKIVO Backup & Replication.

  • The migration occurs for all local tenants at the same time. If the migration fails for one of the tenants, the product reverts to the previous database type automatically.

  1. Go to Settings > General > Database Options.

  2. Select the external database from the list of supported platforms in the Type drop-down list. Note that the internal database is selected by default.

  3. In the Host field, enter the hostname or IP of the server housing the database.

  4. In the Port field, enter the relevant port number.

  5. Enter the name for your database in the Database name field.

  6. Enter Username and Password in the corresponding fields.

  7. Click Test Connection.

  8. If the test is successful, click Apply Settings:

    • If the database does not exist, a dialog box appears asking if you would like to create one and proceed with the migration. Click Migrate.

    • If the database belongs to the current NAKIVO Backup & Replication installation, a dialog box appears asking if you would like to update the settings of the existing database. Click Update to proceed.

    • If the database already exists and is compatible with the current NAKIVO Backup & Replication installation, a dialog box appears asking if you would like to use it, cleanup all its records and replace the contents of the database with the new data. Click Proceed.

Notes

  • If you have the Self-Backup feature enabled, the self-backup process starts before the database switch and runs again after the switch is completed.

  • Self-backup of an external database is possible only with a single-tenant instance of the solution.

  • If the external database is installed on another VM or is using an IP address instead of localhost, take the following steps before migration:

    1. Open the pg_hba.conf file located in the external database installation folder.

    2. Change IPv4 local connections settings from 127.0.0.1/32 to 0.0.0.0/0.

    3. Save changes.

    4. Restart external database service.

  • If the connection between PostgreSQL and NAKIVO Backup & Replication cannot be established, add the following string to the pg_hba.conf file:

    host DATABASE USER ADDRESS METHOD [OPTIONS]

    host all all 0.0.0.0/0 md5

    Note that method (md5) may be different for some versions of PostgreSQL. Check the respective method for your version of PostgreSQL before applying the changes.

  • If Master Tenant connects to existing database that already houses the data from previous migrations, such database is automatically mapped to the tenants during the new migration using the database UUID.

  • It is not possible to recover from a self-backup and system migration in the following cases:

    • The NAKIVO Backup & Replication installation uses the H2 database while the self-backup contains data from an external database.

    • The NAKIVO Backup & Replication installation uses an external database while the self-backup contains data from the H2 database.

  • It is not possible to edit the external database Host, Port, and Database name after a successful migration.

  • If the internal database is used, the product checks the performance capability adequacy of this database to the current product workload:

    • This check is performed every 10 days by default.

    • If the total number of protected workloads for single tenant or per tenant for Multi-Tenant mode exceeds the limit of 100 VMs/instances/physical machines/oracle databases, the product displays the notification with recommendation to switch to the external database.