
Upgrade Bundled PostgreSQL Using QPI Tool
Backup, Upgrade, and Recover Qlik Sense
Overview
In this lesson, you will learn how to get your bundled installation of PostgreSQL server upgraded using the Qlik PostgreSQL Installer (QPI) tool. This process consists of four parts, all of which must be completed in order to successfully upgrade bundled PostgreSQL server. As a quick reference, the four parts are:
Unbundle and Upgrade Qlik Sense Repository Using QPI Tool
Uninstall Qlik Sense Repository Database Service
Reinstall PostgreSQL Binaries
Update Path Environment Variable
Let’s get started!
76
STEPS
56
SCREENSHOTS
HIGH
COMPLEXITY
01. Unbundle and Upgrade Qlik Sense Repository Using QPI Tool
This part consists largely of downloading the QPI tool, running the QPI tool, and providing the QPI tool few pieces of information for it to use to upgrade PostgreSQL server.
Step 01.
Go to Qlik’s Downloads page.
Step 02.
In the Products filter, click the search icon.

Step 03.
Type the word PostgreSQL in the search input box.
Step 04.
Select the Qlik PostgreSQL Installer option.
Step 05.
Click the Qlik_PostgreSQL_setup.exe download link to download the QPI tool.

Step 06.
Stop all Qlik Sense services on rim nodes, if you have any.
Step 07.
Stop all Qlik Sense services except for Qlik Sense Repository Database service in the same order on central node.

Step 08.
Go to the Downloads folder or wherever you downloaded the install file to.
Step 09.
Right-click the Qlik_PostgreSQL_setup_v1.4.0.exe file and select Run as administrator.

Step 10.
Click the Yes button in the User Account Control window.

Step 11.
Click the Upgrade button.

Step 12.
Click the Qlik PostgreSQL Installer instructions link to open documentation explaining how to use the QPI tool.
Step 13.
Click the Qlik Customer Agreement link.

Step 14.
Check both checkboxes to confirm that you’ve read the instructions and agree to Qlik Customer Agreement, if you do.
Step 15.
Click the Next button.

Step 16.
Enter the password of postgres user.
Step 17.
Click the Next button.

Step 18.
Specify the directory where you would like the QPI tool to save the backup of current version of PostgreSQL server contents.
Step 19.
Click the Next button.

Step 20.
Specify where you would like the QPI to install the new, standalone PostgreSQL server.
Step 21.
Click the Next button.

Step 22.
Specify where you would like the new, standalone PostgreSQL server to store its data.
Step 23.
Click the Next button.

Step 24.
Review specified settings and click Upgrade to being unbundling and upgrade process.

Step 25.
Wait for the QPI file to complete.
Step 26.
Notice the note about uninstalling Qlik Sense Repository Database. We will do that next.
Step 27.
Click the Close button to complete the unbundling and upgrade of PostgreSQL process.

02. Review and Confirm Successful Upgrade and Unbundling
Now that PostgreSQL has been upgraded and QPI tool switched Qlik Sense to use the new version of PostgreSQL server, it’s a good idea to launch QMC and the Hub to make sure Qlik Sense is fully operational. In this part, we will make sure that Qlik Sense works as expected and take a note of few things like where to find a backup of old version of PostgreSQL if you will need it.
Step 01.
Launch QMC and confirm that it is operational.

Step 02.
Launch the Hub and confirm that it is operational.

Step 03.
Launch the Services app and confirm that the old Qlik Sense Repository Database service is not running, and the Setup Type is set to Manual.

Step 04.
Confirm that the new postgresql-x64-14 service has been installed and is running.

Step 05.
Go to installation directory of old version of PostgreSQL and notice that the old PostgreSQL directory has been renamed.

Step 06.
Notice also that the backup of the old repository database has been created and saved to the backup folder.

Step 07.
If you open the backup folder and the folder inside it, you’ll see the actual backup file of your old PostgreSQL server.

Step 08.
Right-click the file and select Open with Code option to see contents of the backup file.

Step 09.
Notice that the file contains SQL script that can be run to rebuild original PostgreSQL server’s contents if needed.

Step 10.
Lastly, notice also that the new, standalone PostgreSQL server has been installed in the directory you’ve specified in step 20 above.

This confirms that QPI tool successfully:
Upgraded PostgreSQL server to a newer version.
Converted PostgreSQL into a standalone installation.
And copied the old database to the new, standalone database.
We are not done yet, though. We’re only halfway through. Stopping here will cause issues upgrading Qlik Sense in the future. The last two steps that must be completed are:
Uninstalling Qlik Sense Repository Database service.
And reinstalling PostgreSQL binaries.
03. Uninstall Qlik Sense Repository Database (QSRD) Service
Now that you’ve confirmed that copying of data and upgrade of PostgreSQL server went successfully, the next step is to remove the Qlik Sense Repository Database service that used to run the old PostgreSQL server. Qlik Sense gets “confused” when there are multiple PostgreSQL servers and services installed on one server and that confusion leads to failure in upgrading Qlik Sense in the future.
To ensure that you won’t have issues upgrading Qlik Sense in the future, Qlik Sense Repository Database service must be uninstalled. This is a mandatory step.
What Will Uninstalling QSRD Service Do?
When we will complete this section, two things will happen:
Qlik Sense Repository Database service no longer will be listed



