How to migrate Veeam Backup database to PostgreSQL

Veeam Backup & Replication migrate DB to PostgreSQL

Questo articolo รจ disponibile anche in lingua italiana, al seguente link – Veeam Backup: migrazione da SQL a PostgreSQL – WindowServer.it

In Veeam Backup & Replication v12, an exciting new feature is the support for PostgreSQL as the database for storing the operational schema of the platform. This decision wasn’t made because the company intends to move away from Microsoft SQL Server. Instead, it’s because in typical scenarios, the Express version of SQL Server is used, which isn’t renowned for being phenomenal in production environments due to its limitations:

  • Compute: restricted to the lesser of 1 socket or 4 cores
  • Buffer pool memory: 1410MB
  • Maximum database size: 10GB

So, if our Veeam server is on a physical machine, as it should be, the database can sometimes be a problem, not just for job performance, but also for software usage.

These “limitations” are not present in PostgreSQL, making it an ideal solution for most business scenarios. However, be cautious as this solution may not be suitable when our infrastructure is complex, i.e., with many Veeam objects, a high number of virtual machines, or numerous jobs. Additionally, SQL Server can be configured in AlwaysOn or Failover Cluster modes for advanced scenarios that require total reliability; PostgreSQL does not offer these features.

To migrate the database from SQL Server to PostgreSQL, the procedure is quite straightforward.

The first step is to install PostgreSQL on the Veeam machine. The supported versions start from 14 onwards, but you’ll find version 15 in the Veeam Backup ISO.

Regarding the wizard, there’s not much to say except to recommend keeping the pgAdmin component, which can help you monitor performance.

At this point, it’s necessary to backup the Veeam configuration. Make sure to enable encryption for the backup file if you want to also transfer the credentials of the user accounts used in various jobs.


Once you have completed the initial phase, you can begin the migration process. It’s important to ensure that all jobs are disabled to prevent issues during migration. There’s no need to uninstall anything, as the task supports in-place migration.

Use the Veeam Backup and Replication Configuration Restore tool available on the server. Select the Migration option to start the process.

Choose the most recent configuration file and enter the password to decrypt it.

At this point, you can opt to migrate to the PostgreSQL database.

After verifying that everything is in order, you can initiate the restore process. The duration of this process varies depending on the complexity of your Veeam infrastructure and the number of jobs present. It may take several minutes to complete.

After completing the migration, you can restart the Veeam console. Remember to reactivate the jobs that were previously disabled.

Post Task

A recommended action after completing the migration is to tune PostgreSQL using a PowerShell command. This helps define your server’s structure and optimize the database’s performance. Detailed information on this can be found in the following article – Set-VBRPSQLDatabaseServerLimits – Veeam Backup PowerShell Reference.

Conclusion

This migration procedure is advisable in most scenarios where Veeam is installed as a standalone system and in environments that are not overly complex. It can bring significant benefits in terms of operational performance, both in the use of the console and in the execution of jobs.