Skip to main content

In this article, we will learn how to Migrate Veeam Configuration Database to PostgreSQL Server. I am sure you already know what PostgreSQL is. So let me not bore you with this information as some of our peers have already discussed this topic.

    •  

By default, PostgreSQL is used with all new installs of Veeam Backup & Replication 12. Existing Veeam Backup & Replication deployments that were upgraded from 11a or older will continue to use Microsoft SQL Server until they are manually migrated to PostgreSQL

 

Why switch to PostgreSQL?

Migrating Veeam Backup and Replication from Microsoft SQL Server (MSSQL) to PostgreSQL is driven by various reasons. Below are some common reasons to consider such a migration

Cost saving: If you prioritize cost savings, choosing PostgreSQL for your database needs is an excellent option. It is an open-source database engine that is completely free to use, even for commercial purposes, under the PostgreSQL license.

Mitigate Vendor Lockin: Migrating to PostgreSQL reduces dependency on Microsoft technologies, This is one reason some firms are utilizing open-source technologies. "I love working with Microsoft Technologies". If this is not the case for you, migrating to PostgreSQL can be advantageous for vendor independence or vendor lock-in. Below is a link showing how this can be done on Linux.

  •  

Scalability: This is also a compelling reason to migrate to PostgreSQL. This database is recognized for its scalability and ability to handle large volumes of data and transactions. If your organisation is anticipating significant growth in data volume, migrating to PostgreSQL could provide better scalability and performance.

According to this documentation, Veeam still recommended to use Microsoft SQL Server when you backup more than 5000 VMs.

For more reasons and detailed implementation steps, please see how to Migrate Veeam Configuration Database to PostgreSQL Server.

 

Create a Configuration Backup

Before proceeding with these steps, stop and disable backup jobs. Ensure that you do not initiate or activate any jobs until the migration of Veeam Backup & Replication is finalized.

From the main menu, launch the Configuration Backup Settings as shown below. BTW, here is how to install PostgreSQl on Winows

  •  

 

By default, the “Enable configuration backup to the following repository is selected” is selected. If this is not the case for you, please ensure it is selected. BTW, here is the link to the original blogpost.

Enable Backup file encryption by selecting the checkbox. Click “Backup Now” to create a new backup as shown below.

 

Confirm if the backup pulled is available

 

According to the Veeam documentation, it is pretty safe to ignore the “Loss protection disabled” warning if you do not have Veeam Backup Enterprise Manager installed. This is because. your backup server is not registered with Veeam Backup Enterprise Manager

 

Migrate the Configuration database to PostgreSQL

 

Also from the main menu of the Veeam Backup & Replication console, select Configuration Backup. 

In the Restore section, click Restore.

If you encounter an error that the Veeam Data Mover, or Veeam Installer Services aren’t running, please got to services.msc and start them.

From the Restore Mode window of the Veeam Backup & Replication Configuration Restore wizard, select Migrate, and click on Next.

Select the configuration backup file we created above.

Analyse the configuration file selected

Review the contents

On the Target backup page of the configuration restore wizard, select PostgreSQL as the database engine.

 

 

The configuration restoration completed successfully. Click next to proceed

 

Click Finish on the Summary page

 

Now that the restore process has been completed. Ensure that PostgreSQL target instance is configured according to the recommended hardware resource values.

 

If you set PostgreSQL database as a configuration database when you install Veeam Backup & Replication, the necessary resource capacity will be configured during Veeam Backup & Replication installation.
- If the CPU or RAM resources are changed after Veeam Backup & Replication or Veeam Backup Enterprise Manager installation, you must run this cmdlet again to adjust hardware resources of the PostgreSQL instance.

 

 

Launch the VBR Console again and perform the Configuration file backup

That is all that needs to be done. Some of the errors I encountered, I will blog on them and link them to my original blog post. The below are similar errors you will encounter when performing configuration db migration.

  •  

Really great article. Did this in our lab without issue. 👍


Really great article. Did this in our lab without issue. 👍

Good to know, thanks!


Nice PGSQL mirgration summary Christian! 👍🏻


Nice PGSQL mirgration summary Christian! 👍🏻

Thank you!


One tip - if you are using VEM as well you must migrate that and then re-add VBR to the console (delete/add).  If not, you cannot manage a VBR server on PG and VEM on SQL.  The VEM move is fun as it is command line based too.  😁


Great write up! I’ll be doing this next migration 


Great procedure, thanks and worked exactly as described. We now have the DB resync job running does anyone know how lomg this may take as all backups/replications are disabled until it has completed so was just wondering what timescales we could expect? 


Great procedure, thanks and worked exactly as described. We now have the DB resync job running does anyone know how lomg this may take as all backups/replications are disabled until it has completed so was just wondering what timescales we could expect? 

You are welcome. I would advise you to take a look at this link: https://forums.veeam.com/vmware-vsphere-f24/configuration-database-resynchronize-t28396.html


Thanks Iams3le, unforunately that really applies to the normal scans/rescans performed. In this instance the resync job runs on all the repos in one go so we are currently at 20 hours and I reckon only half way through. I would suggest you add this step into the procedure as that was quite quick and was as per this procedure however we didn’t realise we would be without backups and replications for this long. It causes us problems with our Oracle RMAN backups as no archive log backups mean our FRA’s fill up 


Comment