top of page

Recovery Process Summary

Backup, Upgrade, and Recover Qlik Sense

Overview

In this lesson, we’ll take a look at the process, at high-level, of recovering a Qlik Sense server from backups.

For years I feared and hoped to never have to be in a position to recover a Qlik Sense server from backups. Qlik Sense is an enterprise software that businesses invest millions of dollars and years of time to develop. Being responsible for keeping a set of Qlik Sense servers operational and resilient to damages and losses can be a stressful responsibility, but that’s why we, Qlik Sense server Admins, get paid big bucks.

If you also feel, let’s say, a slight discomfort when thinking about a scenario where you will be responsible for recovering a Qlik Sense server from backups, having gone through several successful Qlik Sense server recoveries, I can tell you it’s not as challenging as you may imagine it.

Recovering Qlik Sense with Standalone PostgreSQL

For reference, here are the high-level steps that will need to be taken when recovering Qlik Sense with a standalone installation of PostgreSQL:

  1. Recover certificates

  2. Install PostgreSQL server

  3. Run command to recover PostgreSQL databases, users, indexes, etc.

  4. Run command to generate PostgreSQL optimizer statistics

  5. Install Qlik Sense

  6. Install Qlik Sense patch

    1. This is applicable only if the version of Qlik Sense that you are recovering had a patch installed.

  7. Recover directories

    1. These are things like contents of shared root folder, logs, and configuration files.

    2. Compare and merge applicable config files. This is also largely only applicable for scenarios when recovering Qlik Sense on a server with a different name.

  8. Update server host name

    1. This is applicable only if recovering Qlik Sense on a server with a different server name.

    2. If recovering Qlik Sense on the same server where it was before, there’s no need to run the process to update host name.

  9. Update certificate’s thumbprint in Proxy settings in QMC

    1. This is also applicable only if recovering Qlik Sense on a server with a different name.

  10. Recover backup scripts and tasks

Recovering Qlik Sense with Bundled PostgreSQL

If you’re recovering a server that used a bundled installation of PostgreSQL, you would follow very similar set of steps, but in slightly different order. Here are the steps you would take to recover Qlik Sense with a bundled installation of PostgreSQL:

  1. Recover certificates

  2. Install Qlik Sense

  3. Install Qlik Sense patch

    1. This is applicable only if the version of Qlik Sense that you are recovering had a patch installed.

  4. Run command to recover PostgreSQL databases, users, indexes, etc.

  5. Run command to generate PostgreSQL optimizer statistics

  6. Recover directories

    1. These are things like contents of shared root folder, logs, and configuration files.

    2. Compare and merge applicable config files. This is also largely only applicable for scenarios when recovering Qlik Sense on a server with a different name.

  7. Update server host name

    1. This is applicable only if recovering Qlik Sense on a server with a different server name.

    2. If recovering Qlik Sense on the same server where it was before, there’s no need to run the process to update host name.

  8. Update certificate’s thumbprint in Proxy settings in QMC

    1. This is also applicable only if recovering Qlik Sense on a server with a different name.

  9. Recover backup scripts and tasks

These are the steps and the order in which they must be completed. Let’s take a closer look at each of them as well as at some recovery scenarios and prerequisites that will need to be in place when recovering a Qlik Sense site.

12

POINTS

1

TAKEAWAY

MED

COMPLEXITY

01. Recover Certificates

Certificates play a critical role in Qlik Sense server’s security. They secure communications between Qlik Sense server and PCs that employees use to view Qlik Sense apps. Certificates secure communications that are going on behind the scenes between Qlik Sense services. They secure passwords of data connections and they are used to secure communications between on-prem and Qlik Sense SaaS or Qlik Sense Cloud deployments.

Certificates are very important to successful recovery of a Qlik Sense server. They must be backed up and they must be recovered for a Qlik Sense server to resume operations without delays or issues.


02. Install PostgreSQL Server

I don’t know the exact percentage of Qlik’s clients that run a standalone installation of PostgreSQL, but with the introduction of Qlik PostgreSQL Installer (QPI) tool, I imagine the percentage is high. Standalone installation of PostgreSQL provides several advantages over the bundled installation, namely the flexibility to update PostgreSQL server to a broader selection of versions, on a schedule that best fits your team, and without the need to uninstall, reinstall, and recover Qlik Sense from backups.

If you have a Qlik Sense server in your environment that is using a standalone installation of PostgreSQL, after restoring certificates, the next step you will take is install PostgreSQL.

However, if the server that you are recovering used a bundled installation of PostgreSQL, you can skip this step as PostgreSQL will be installed during installation of Qlik Sense.


03. Recover PostgreSQL Databases, Users, Indexes, etc.

Once you have PostgreSQL installed, the next step will be to run a simple command to bring back all of the contents that lived inside of PostgreSQL server. The command will look something like this:

The QSDatabaseBackup.sql  file would be the backup file that contains contents of PostgreSQL server that needs to be recovered. This file is created as part of the backup process which was covered in the Backup section of this course.

If you are recovering a Qlik Sense server that uses a bundled installation of PostgreSQL, you will need to run the same command, but you’ll run it after you complete installation of Qlik Sense.


04. Generate PostgreSQL Optimizer Statistics

Just like after upgrading a PostgreSQL server, we’ll need to run a single command to generate query optimizer statistics after recovering PostgreSQL server contents to give PostgreSQL what it needs to be able to run queries and operate at optimal level.

The command to generate optimizer statistics is:


05. Install Qlik Sense

Once the certificates and PostgreSQL databases have been recovered, you’ll be ready to install Qlik Sense. Key thing to remember is that you must install the same version of Qlik Sense as the version that the server that you’re recovering used. Or, to put it differently, if you created backups of November 2024 version of Qlik Sense, you must install the same November 2024 version of Qlik Sense when recovering Qlik Sense. In order to successfully recover Qlik Sense from backups, the version of Qlik Sense that was backed up must match the version installed during recovery.

Another thing to note is that during installation of Qlik Sense, you’ll see this screen:

This is the step where you will select whether you want to connect Qlik Sense to a standalone PostgreSQL installation that you’ve installed and recovered earlier or install a bundled installation of PostgreSQL server.

Last thing to remember during installation of Qlik Sense is to uncheck the option to start Qlik Sense services after Qlik Sense is installed. You will see this option close to the end of the installation wizard on this screen:


06. Install Qlik Sense Patch

If the version of Qlik Sense that you’ve backed up had a patch installed, you will need to install the same patch when recovering Qlik Sense. If you backed up a patched version of Qlik Sense but don’t install the same patch during Qlik Sense server recovery, your Qlik Sense will be operational, but the side-effect of a missing patch will be that none of the apps will be opening in the Hub.

The good news is that even if you’ll forget to install the patch and experience issues because of that, taking Qlik Sense offline and installing the patch after the fact usually resolves the issues derived from a missing patch. Still, it’s best to install the patch at this step to avoid any issues later on.

If you’re not sure if your Qlik Sense server had a patch installed, I recommend skipping this step. You will be able to see whether or not your server had a patch installed in QMC, here:

Once you complete the recovery process, launch QMC, and check if a patch is mentioned in the bottom right corner of the Start page in QMC. If you see the patch mentioned, that means that the backed up version had a patch installed. It will also tell you exactly which patch you will need to install. If you haven’t installed the patch during recovery process and discovered that backed up version had a patch installed, shut down Qlik Sense services, install appropriate patch, and bring Qlik Sense services back online.


07. Recover Directories

Now that you have certificates, PostgreSQL server, and Qlik Sense installed and recovered, the last thing that will need to be recovered are backed up directories. Here you will recover contents of Shared root folder, ProgramData directory, and Program Files directory.

Shared root folder directories will hold things like apps, extensions, contents of content libraries, logs and more.

Data stored in ProgramData directory will largely be log files although it may also contain some configuration files, especially if you’re recovering a Qlik Sense server with a bundled installation of PostgreSQL.

And Program Files directory will largely contain backed up configuration files that will ensure that any custom configuration changes made to backed up version of Qlik Sense will also be present on recovered version.


08. Update Server Host Name

This process is only needed when recovering Qlik Sense on a server with a different server name. If you’re recovering Qlik Sense on the same server as it used to run on, you can skip this step.

There are several components of Qlik Sense that are tied to the name of a server where Qlik Sense is installed. Primarily the certificates. Certificates are issued and can only be used on a machine with a specific name. If you’re recovering Qlik Sense server on a server with a different server name, Qlik put together a handy tool for us Qlik Sense Admins to use that will go through Qlik Sense and update any places where old server’s name is used to reference the new server’s name.

The process to update server host name is really just a single command that will need to be executed, and it will handle renaming every place and updating Qlik Sense certificates to reference the new server’s name. The command to run the process to update server host name is:

There are few extra steps that you will need to take during the execution of this command. The complete process is covered in Update Server Host Name lesson.


09. Update Certificate’s Thumbprint

Second to last step in recovery process is also only applicable if you are recovering Qlik Sense on a different machine and if you are using an SSL / TLS certificate issued by either an internal or third-party certification authority (CA) to secure communications between your Qlik Sense server and client PCs.

The idea here is that when recovering Qlik Sense on a new server, more specifically on a server with a different name, you will need to obtain a new SSL certificate specifically for this new server. Since you’re recovering Qlik Sense on a different machine, on a machine with a different name, even if you’ll recover the certificate from previous server, the users will still see this error message when accessing Qlik Sense:

This happens because client PCs will see that the certificate that is used by the new Qlik Sense server, the server on which you recovered Qlik Sense, has a different name than the name listed in the certificate. Because the name of the server where the recovered Qlik Sense is running doesn’t match the name of the server in certificate, browsers will reject the certificate, even if you have a private key for that certificate.

To resolve this issue, you will need to get a new certificate for the new server, install the new certificate on the new server, and replace the certificate thumbprint that is listed in Proxy settings in QMC with the thumbprint of the new certificate. More on that in Update Proxy Settings to Use New Certificate  lesson.


10. Recover Backup Scripts & Tasks

Last, but certainly not least, set of steps will involve recovering PowerShell script and Task Scheduler tasks needed to continue backup of Qlik Sense after it has been recovered. This step is also largely only applicable when recovering Qlik Sense on a different server, but it may also apply when recovering Qlik Sense on the same machine. It depends on the reason for the need to recover on the same machine. In any case, it’s always important to ensure that backups of the server continue to take place on a regular basis.


11. Prerequisites

When recovering Qlik Sense on a server with a different name, you will typically need the following things in place:

  • A new, fully-configured and secured server.

  • Applicable software installed.

    • Software like PowerShell, PowerShell modules, Visual Studio Code, pgAdmin, etc.

  • Certificate for client-server communications obtained and installed.

The overarching idea here is to have a server on standby with the only thing missing from it is Qlik Sense and its data. The goal is to set yourself up for the smoothest and fastest recovery process.

At the minimum, you will want to make sure that standby server has:

  • Appropriate Firewall rules are created.

  • Shared root folder for Qlik Sense is created and secured.

  • PowerShell along with SecretManagement and CredMan modules is installed.

  • Credentials for PostgreSQL superuser added to Credential Manager to be used in backups automation.

  • And a new certificate issued and installed on the new server.

Keep in mind that doing things like having applicable Firewall rules created, a new certificate issued, and applicable software installed may require involvement from other teams within your organization. I recommend thinking about everything that you will need to have in place on a new server and who will need to be involved to get everything that you need installed and configured on the new server. Then, once you have the list ready, I recommend addressing ahead of time anything that will require involvement from other teams. This way you will minimize the chance of delays in the recovery process because the team or individual that you need to do a specific task on the new server is not available when you need them.


12. Recovery Scenarios

Lastly, for context, I’ll mention some scenarios why or when you will need to recover a Qlik Sense server. From my experience, most likely scenario when you will need to recover a Qlik Sense server on the same machine will be when an upgrade needs to be rolled back for whatever reason.

As for recovering Qlik Sense on a different machine, the need to do that most often comes from the need to upgrade the server hardware to newer, more powerful server. Luckily, in my career, I’ve never needed to recover a Qlik Sense site due to failed hardware, but that is also not an impossible scenario for the need to recover a Qlik Sense server on a different machine.

In any case, what I will show you in the rest of the course is how to recover a Qlik Sense server from the scenario where the entire server is lost and all you have left are backups. This way, you will see how to recover certificates, and repository databases, and logs, and everything else that needs to be recovered to bring your Qlik Sense server back online.

Guide

Summary

All Set!

That’s really it. Key takeaway is that there are four possible sets of steps to follow when recovering Qlik Sense server from backups. Which set of steps you take depends on whether you're recovering a Qlik Sense server that used a bundled or standalone installation of PostgreSQL server and whether you're recovering Qlik Sense on the same machine it was installed previously or on a different machine - a machine with a different name.

As long as you have complete backups of your Qlik Sense server, you should be able to recover Qlik Sense by following the 9 to 10 high-level steps mentioned in the Overview section of this lesson.

For added clarity, I’ll also list the four options and corresponding steps involved in these options for recovering a Qlik Sense server.

Recovering Qlik Sense with Standalone PostgreSQL

On a Server with Different Server Name

  1. Recover certificates

  2. Install PostgreSQL server

  3. Run command to recover PostgreSQL databases, users, indexes, etc.

  4. Run command to generate PostgreSQL optimizer statistics

  5. Install Qlik Sense

  6. Install Qlik Sense patch, if applicable

  7. Recover directories

  8. Update server host name

  9. Update certificate’s thumbprint in Proxy settings in QMC

  10. Recover backup scripts and tasks

On a Server with Same Server Name

  1. Recover certificates

  2. Install PostgreSQL server

  3. Run command to recover PostgreSQL databases, users, indexes, etc.

  4. Run command to generate PostgreSQL optimizer statistics

  5. Install Qlik Sense

  6. Install Qlik Sense patch, if applicable

  7. Recover directories

  8. Recover backup scripts and tasks

 

Recovering Qlik Sense with Bundled PostgreSQL

On a Server with Different Server Name

  1. Recover certificates

  2. Install Qlik Sense

  3. Install Qlik Sense patch, if applicable

  4. Run command to recover PostgreSQL databases, users, indexes, etc.

  5. Run command to generate PostgreSQL optimizer statistics

  6. Recover directories

  7. Update server host name

  8. Update certificate’s thumbprint in Proxy settings in QMC

  9. Recover backup scripts and tasks

On a Server with Same Server Name

  1. Recover certificates

  2. Install Qlik Sense

  3. Install Qlik Sense patch, if applicable

  4. Run command to recover PostgreSQL databases, users, indexes, etc.

  5. Run command to generate PostgreSQL optimizer statistics

  6. Recover directories

  7. Recover backup scripts and tasks

Hopefully, this makes the recovery process clearer and less intimidating. In the remainder of the course, you will learn how to recover Qlik Sense with standalone and bundled PostgreSQL installation on a server with a different name. If you’re recovering a Qlik Sense server on the same machine, simply skip the Update Server Host Name and Update Proxy Settings to Use New Certificate lessons.

Let’s get the recovery process started by recovering certificates! I’ll see you in the next lesson.

Update Server Host Name

HOWDASH LESSON

Learn the steps to update server host name when recovering Qlik Sense server from backups on a server with a different name.

Update Proxy Settings to Use New Certificate

HOWDASH LESSON

Learn how to swap the certificate thumbprint in QMC to ensure Qlik Sense runs securely with a certificate issued to the new server.

References

Up Next

Recover Certificates (Standalone)

Copyright © 2023 howdash LLC

Guides

Enroll

01. Backup Automation

Introduction to Backups

01. Backup Automation

01. Backup Automation

01. Backup Automation

01. Backup Automation

01. Backup Automation

01. Backup Automation

Backup Automation Map

01. Backup Automation

01. Backup Automation

01. Backup Automation

01. Backup Automation

01. Backup Automation

01. Backup Automation

01. Backup Automation

01. Backup Automation

01. Backup Automation

01. Backup Automation

01. Backup Automation

Stop Qlik Sense Services

01. Backup Automation

Start Qlik Sense Services

01. Backup Automation

01. Backup Automation

01. Backup Automation

01. Backup Automation

01. Backup Automation

01. Backup Automation

01. Backup Automation

01. Backup Automation

01. Backup Automation

01. Backup Automation

01. Backup Automation

02. Upgrade

02. Upgrade

02. Upgrade

02. Upgrade

02. Upgrade

02. Upgrade

02. Upgrade

02. Upgrade

02. Upgrade

02. Upgrade

02. Upgrade

02. Upgrade

02. Upgrade

02. Upgrade

02. Upgrade

02. Upgrade

02. Upgrade

02. Upgrade

02. Upgrade

02. Upgrade

02. Upgrade

02. Upgrade

02. Upgrade

02. Upgrade

03. Recover

03. Recover

03. Recover

03. Recover

03. Recover

03. Recover

03. Recover

03. Recover

03. Recover

03. Recover

03. Recover

03. Recover

03. Recover

03. Recover

04. Bonus

bottom of page