How To Migrate a Veeam Backup & Replication Configuration Database to PostgreSQL

Before Veeam Backup & Replication v11, the product used SQL Server to create and store its configuration database. It has always been possible to use SQL Server Express to store a Veeam Backup & Replication, however, this version of SQL Server had some critical limitations. In the 2022 version of SQL Server Express, the most relevant limitations were:

  • Use of one socket or four cores
  • Use of only 1.4GB per instance
  • 10GB limit for databases

In an environment of 500 machines or fewer, these limitations may not have an impact, but if you have a large backup environment, you had to migrate to one of the paid SQL Server versions to avoid these limitations.

You can check the limits for each version of SQL Server 2022 by clicking this link.

For V12 and with scalability, performance and licensing cost in mind, Veeam introduced the possibility of using PostgreSQL as a configuration database. PostgreSQL is a relational database management system that’s been used for over 35 years by a number of platforms. In addition to being proven to be robust and effective, PostgreSQL also has open-source code and can be used without paying licensing costs.

In V12 you can use both SQL Server and PostgreSQL as a configuration database, whereas with V11, you could only use SQL Server. If you’re coming from V11 to V12,  the configuration will continue to use SQL Server by default. To use PostgreSQL, you need to migrate your configuration database.

In this article, I will cover the necessary steps you need to perform  this migration, including installing PostgreSQL, creating a configuration backup and migrating your database.

Limitations and Considerations

Before we start, it is important to cover some important considerations:

  • It is recommended that you only use the method below to migrate your database to avoid errors.
  • You must upgrade to V12 before migrating to PostgreSQL.

PostgreSQL Installation

Veeam supports PostgreSQL from version 14 and up. In the installation ISO, you can find the installer for version 15.1 in the path: “Redistr\x64\PostgreSQL\15.1-1”.

Let’s start the PostgreSQL installation.

Choose the path where you want the program installed.

Select the components you want to install. Leave at least PostgreSQL Server, pgAdmin and Command Line Tools selected.

Select the path where you want your databases to be stored.

Set a password for the PostgreSQL administrator user.

Set the port you want to use for the PostgreSQL service.

Choose the default locale you want your databases to use.

Verify that all options are correct and start the installation.

After the installation finishes, open pgAdmin.

For this example, I will create a local user in PostgreSQL named “veeam” with Superuser permissions so that it can create a Veeam database and perform all necessary processes during the migration process.

Creating a Veeam Backup & Replication Configuration Backup

Now that we have PostgreSQL installed and configured, let’s create a backup and configuration for the current Veeam database.

Open the configuration backup:

Click “Backup Now” to create a new backup.

It is important that your configuration backup encryption is enabled so that user passwords for the Veeam infrastructure are also exported. Otherwise, you will need to enter all user passwords during the migration.

At the end of the process, validate that the backup is available in the repository.

Migrating the Configuration Database to PostgreSQL

Now we will migrate the database to PostgreSQL.
Disable all backup jobs to ensure that nothing will run this process.
Close the console and open the “Configuration Restore” application.

Select the “Migrate” option.

Choose the configuration backup file we created earlier.

Validate the backup content.

Enter the encryption password for the configuration backup file.

Choose the PostgreSQL option in “Database engine”, enter the server name (or localhost) and the port that PostgreSQL is using. Then, define the database name and enter the user and password to connect to PostgreSQL.

You will be notified that the database does not exist and will be created during this process.

Choose whether you want to restore the Veeam Backup & Replication catalog and session history.
We can also enable an option to require a PowerShell Execution Policy for System Center VMM.

You will get a notification that services will be restarted.

Monitor the restore process and wait for it to finish.

Since the configuration backup file was encrypted, user passwords were also imported.
If necessary, they can be edited.

After this finishes, we can open the console again.

In PgAdmin, we will see that the Veeam Backup & Replication database has been created and is already in use.

Lastly, it is recommended that you execute the “Set-VBRPSQLDatabaseServerLimits” command in PowerShell to modify the hardware parameters in PostgreSQL’s configuration to comply with Veeam’s best practices.Open PowerShell and execute the command.

Restart the PostgreSQL service for the new settings to take effect.

If SQL Server Express is being used exclusively for Veeam Backup & Replication, now that we have migrated the database to PostgreSQL, it is safe to completely remove it from the Windows Server.

With this, we have completed the migration of your configuration database.
In our user guide, you can find the steps we followed in this article.

Similar Blog Posts
Technical | January 10, 2024
Business | November 17, 2023
Business | November 16, 2023
Stay up to date on the latest tips and news
By subscribing, you are agreeing to have your personal information managed in accordance with the terms of Veeam’s Privacy Policy
You're all set!
Watch your inbox for our weekly blog updates.