Skip to main content
Announcements
Qlik Connect 2024! Seize endless possibilities! LEARN MORE
cancel
Showing results for 
Search instead for 
Did you mean: 
mwallman
Creator III
Creator III

How does Qlik Sense Load Balance CPU, RAM, Users in a multi-node environment?

Hello all,

How does Qlik Sense Load Balance CPU, RAM, Users in a multi-node environment?

We have a multi-node environment where we can see sometimes Server 1 CPU spikes, sometimes Server 2 spikes in RAM, sometimes one of the servers spiking in handling concurrent users. I am taking this info from Monitoring Apps.

How does Qlik decide which server to utilise when it comes to these resources/activities?

We have all 5 services enabled in each node.

2 Replies
Chip_Matejowsky
Support
Support

Hi @mwallman ,

Have a look at the Qlik Support article "Load Balancing in Qlik Sense".

More information can be found on the Qlik Sense help site here.

 

Hope this helps.

-Chip

Principal Technical Support Engineer with Qlik Support
Help users find answers! Don't forget to mark a solution that worked for you!
Levi_Turner
Employee
Employee

It's ultimately pure round robin. But to give it some technical color, let's break this down into it's components. When a user opens the Hub there are the following dependencies:

  • A virtual proxy:
    • This defines the authentication mechanism which will be used
    • A given virtual proxy can have one to many Engines load balanced against this
      • What apps are available on each Engine is governed by the Load Balancing Rules in place. By default all apps except the apps in the Monitoring Apps stream are load balanced to RIM nodes
  • A session on the Engine
    • Type 1: A rendering of the Hub, i.e. providing an app list
    • Type 2: Delivering a particular app

So in a scenario where a user accesses a virtual proxy, there is an array of available Engines.

  • User 1:
    • Engine 1 in the list will render the Hub
    • The first app opened will be routed to the next Engine which has the app available (from the load balancing rules); let's assume that all apps are on all nodes so it'll be Engine 2
    • The second app will be routed to the next Engine which has the app available; with assumptions this will be Engine 3
  • User 2:
    • Engine 4 will render the Hub
    • First app --> Engine 5
    • ....

Bringing it back to the crux of your question, it's round robin so there are scenarios where Engines can be overloaded. In these scenarios, it can be advantageous to explore pinning applications to nodes. Typically this is done for the largest apps or for a specified stream. With app pinning, you can ensure that 1 to many Engines solely deliver requests for those apps. This increases the re-use of cache rather than diffusing the consumption of those apps across all the available Engines.

In terms of determining which apps to target, generally folks know what their largest apps are, but a tool like https://github.com/eapowertools/qs-app-metadata-analyzer/ can be used in a pinch. Now the RAM measurement that it provides is purely based on the data model and not the visualization layers, so note that. But it's good enough for a first approximation of things. It also does a good job of visualizing the effective result of the interaction of the load balancing rules in the environment.