Installing or upgrading PostgreSQL using the Qlik PostgreSQL Installer
The Qlik PostgreSQL Installer (QPI) facilitates your installation or upgrade of the bundled PostgreSQL database. The QPI can be used when installing a completely new database based on PostgreSQL 12.5, or when upgrading an existing database from PostgreSQL 9.6 to PostgreSQL 12.5.
About the Qlik PostgreSQL Installer
As of March 2023, PostgreSQL 9.6 is no longer supported. Using the QPI when upgrading to PostgreSQL 12.5 simplifies the upgrade. The QPI also makes the installation of a new database easier.
When you launch the QPI, it detects any already existing PostgreSQL setup and starts the upgrade process. If no PostgreSQL setup is detected, the QPI starts the installation process.
The default installation path is C:\Program Files\PostgreSQL\12. Data for the new database is stored at C:\Program Files\PostgreSQL\12\data.
You can change these paths, as long as they don't use the old path: C:\Program Files\Qlik\Sense\Repository\PostgreSQL\12.5. The change of paths is made to decouple PostgreSQL from Qlik Sense and facilitate maintenance and upgrading. With this change there is no dependency on upgrades to Qlik Sense Enterprise on Windows. Any attempt to use the old installation path is automatically prevented to avoid issues with the database being interpreted as bundled by the installer when upgrading.
The QPI only supports Qlik Sense Enterprise on Windows February 2022 and above.
When upgrading, the database backup is stored in C:\ProgramData\Qlik\Sense\Repository\PostgreSQL\backup\9.6. The 9.6 folder is renamed to 9.6_deprecated, to avoid accidental references to the old 9.6 folder.
Supported scenarios
You can use the QPI in the following scenarios:
-
Making a clean installation of PostgreSQL 12.5. The QPI only supports Qlik Sense Enterprise on Windows February 2022 and above. It's recommended that you upgrade to the latest supported version of Qlik Sense before using the QPI.
-
Upgrading an existing QRD from PostgreSQL 9.6 to 12.5. Upgrading earlier versions of the QRD is not supported through this method. Instead, upgrade to a version of Qlik Sense that supports 9.6 to automatically migrate through the minor version.
-
Installing a new QRD cluster on a new server, for a new environment, or migrate an existing database to a separate host.
For more information about the QPI, see: Upgrading and unbundling the Qlik Sense Repository Database using the Qlik PostgreSQL Installer.
Considerations
Before you start installing or upgrading, consider the following:
-
The QPI will not detect a standalone PostgreSQL database installed by any other means other than through an official Qlik installer package.
-
The QPI itself does not provide a rollback feature.
-
The user who runs the QPI needs to have sufficient permissions to execute the QPI and install services.
-
The user who runs the QPI needs to have sufficient permissions to create folders and files in the backup destination.
-
The backup destination needs to have sufficient free disk space to dump the existing database.
-
The backup destination is not a network path or virtual storage folder. It's recommended to store the backup on the main drive.
-
There will be downtime during this operation, plan accordingly.
Installing a new Qlik Sense Repository Database using PostgreSQL 12.5
Do the following:
-
Stop all services on rim nodes.
-
Run the Qlik PostgreSQL Installer.
-
Click Install.
-
Accept the Qlik Customer Agreement.
-
Set the Local database settings and click Next. You will use these details to connect other nodes to the same cluster.
-
Set the Database superuser password and click Next.
-
Review the settings and click Install and then Finish.
-
Do one of the following:
-
Restore your existing QRD database, see: Restoring a Qlik Sense site.
-
Start installing Qlik Sense Enterprise Client-Managed, see: How to configure Qlik Sense to use a dedicated PostgreSQL database.
-
-
When the installation is complete, close the installer.
-
Click Finish to complete the installation.
Upgrading an existing Qlik Sense Repository Database using PostgreSQL 12.5 - Central node
Do the following:
-
Stop all services on the rim nodes.
-
On your central node, stop all services except the Qlik Sense Repository Database service.
-
Run the Qlik PostgreSQL Installer. The installer will detect the existing database.
-
Click Upgrade.
-
Accept the Qlik Customer Agreement.
-
Enter your Database superuser password and click Next.
-
Set the backup location and click Next.
-
Click Upgrade and then Finish.
A new service named postgresql-x64-12 is now installed. It's run by the Network Service account. Don't change the name of the service and don't modify the account running it.
-
Start all services except the Qlik Sense Repository Database service.
-
Start all services on the rim nodes.
-
Validate that all services and nodes are operating as expected.
-
Once the upgrade and all validation are complete, remove the old Qlik Sense Repository Database from the server.
Information noteThis step is required. Failing to remove the old service will lead the upgrade or patching issues.-
Open a command prompt and run the following command:
c:\cd ProgramData\Package Cache
-
From there, run:
c:\ProgramData\Package Cache\dir /s PostgreSQL.msi
The folder containing PostgreSQL.msi is displayed.
-
Right-click the PostgreSQL.msi file and select Uninstall from the menu.
-
If the upgrade was unsuccessful and you are missing data in the Qlik Management Console or elsewhere, contact Qlik Support.