Multi-monitor support
Overview
The Linux VDA provides the out-of-the-box multi-monitor support with a default resolution of 2560×1600 per monitor. Standard VDAs support up to nine monitors, and HDX 3D Pro VDAs support up to four monitors.
This article describes how to configure the Linux VDA for different monitor resolutions and layouts.
Virtual session desktop
Like the Windows VDA, the Linux VDA has the concept of a multi-monitor virtual desktop. It is based on the bounding rectangle of all monitors, not the actual layout of the monitors. Thus, the area of the virtual desktop can theoretically be larger than the area covered by the monitors of the client.
Virtual session desktop size
The origin of the virtual session desktop is calculated from the top-left corner of the bounding rectangle of all monitors. That point locates at X = 0, Y = 0, where X and Y are the horizontal and vertical axes, respectively.
The width of the virtual session desktop is the horizontal distance, in pixels, from the origin to the top-right corner of the bounding rectangle of all monitors.
Similarly, the height of the virtual session desktop is the vertical distance, in pixels, from the origin to the bottom-left corner of the bounding rectangle of all monitors.
This calculation is important for the following reasons:
- Allowing for different client monitor layouts
- Understanding memory usage on the Linux VDA
Allowing for different client monitor configurations
Knowing the maximum virtual desktop size for your various client monitor configurations allows you to configure the Linux VDA to be flexible in terms of client monitor configurations.
Consider the following client monitor configuration:
The diagram above shows an out-of-the-box multi-monitor configuration with two monitors, each with a resolution of 2560×1600.
Now, consider connecting to the same Linux VDA with the following client monitor configuration:
If each monitor in the above diagram has a resolution of 2560×1600, the out-of-the-box multi-monitor configuration parameters are insufficient. The maximum height is too small to accommodate the virtual session desktop for this monitor layout. To accommodate the client monitor configuration in this example, you must set the Linux VDA virtual desktop to a size of 4160×2560.
For the greatest flexibility in a multi-monitor configuration, find the smallest bounding rectangle of all monitor layouts you want to support. For configurations with two 2560×1600 monitors, the possible layouts include:
- Monitor1 2560×1600 and Monitor2 2560×1600
- Monitor1 1600×2560 and Monitor2 2560×1600
- Monitor1 2560×1600 and Monitor2 1600×2560
- Monitor1 1600×2560 and Monitor2 1600×2560
To accommodate all the layouts above, you need a virtual session desktop of 5120×2560. It is the smallest bounding rectangle that can contain all the desired layouts.
If all your users have only one monitor in the typical landscape layout, set the maximum virtual desktop size to the highest resolution of the monitor.
In this example, the virtual desktop needs to be set to a size of 2560×1600. Because the default configuration is 5120×1600 and 2 monitors, a configuration change is required to optimize memory usage for single-monitor deployments.
Note:
If a desktop displays at an improper resolution in a multi-monitor setup, adjust Dots Per Inch (DPI) settings on the Citrix Workspace app. For more information, see Knowledge Center article CTX230017.
Understanding memory usage on the Linux VDA
Knowing the virtual desktop size allows you to calculate the amount of memory used by each HDX session. This memory is the memory allocated to each session for its graphics data when the session begins. It does not change for the life of the session. While this memory is not the total amount of memory used for the session, it is the easiest way of calculating per-session memory usage.
To calculate how much memory is allocated to each HDX session, use the following formula:
M = X × Y × Z,
Where:
- M is the amount of memory used for session graphics.
- X is the width of the virtual session desktop.
- Y is the height of the virtual session desktop.
- Z is the color depth of the HDX session window. The value is in bytes, not bits, so use 4 for 32-bit color.
NOTE:
The color depth of the X server starts and cannot change with the life of the session (from login through disconnects/reconnects until logoff). Hence, the Linux VDA always allocates the virtual session desktop as 32-bit and down samples to the color depth requested for the session.
For example, for a 1024×768 session, the memory used is:
1024 × 768 × 4 / 2^20 MB = 3 MB
Understanding memory usage is important for increasing session density on each Linux VDA.
Consider the following client monitor configuration:
If each monitor has a resolution of 2560×1600, to accommodate this client monitor configuration, the virtual session desktop size needs to be 5120×3200. Notice that the gray area is unused and equates to 16,384,000 (that is, 2560 x 1600 x 4) bytes of wasted memory.
Citrix multi-monitor configuration parameters
You can control the multi-monitor functionality of the Linux VDA by using the following configuration parameters:
-
MaxScreenNum
Parameter: HKEY_LOCAL_MACHINE/System/CurrentControlSet/Control/Citrix/Thinwire/MaxScreenNum
Description: Number of monitors to support
Type: DWORD
Default: 4
Maximum: 9 for standard VDA, 4 for HDX 3D Pro VDA
-
MaxFbWidth
Parameter: HKEY_LOCAL_MACHINE /System/CurrentControlSet/Control/Citrix/Thinwire/MaxFbWidth
Description: Maximum width of a virtual session desktop
Type: DWORD
Default: 5,120
Maximum: 16,384 (8,192 x 2)
-
MaxFbHeight
Parameter: HKEY_LOCAL_MACHINE /System/CurrentControlSet/Control/Citrix/Thinwire/MaxFbHeight
Description: Maximum height of a virtual session desktop
Type: DWORD
Default: 1,600
Maximum: 16,384 (8,192 x 2)
Changing the Linux VDA multi-monitor configuration
The following section outlines how to enable, configure, and disable the multi-monitor functionality on the Linux VDA.
Set the maximum number of monitors by using:
sudo ctxreg create -k " HKEY_LOCAL_MACHINE \System\CurrentControlSet\Control\Citrix\Thinwire" -t "REG_DWORD" -v "MaxScreenNum" -d "NumMons" --force
<!--NeedCopy-->
Where NumMons
is a value between 1 and 9 for standard VDA or 1 and 4 for HDX 3D Pro VDA.
Set the maximum width of a virtual session desktop by using:
sudo ctxreg create -k " HKEY_LOCAL_MACHINE \System\CurrentControlSet\Control\Citrix\Thinwire" -t "REG_DWORD" -v "MaxFbWidth" -d " MaxWidth" --force
<!--NeedCopy-->
Where MaxWidth
is a value between 1,024
and 16,384
.
Set the maximum height of a virtual session desktop by using:
sudo ctxreg create -k " HKEY_LOCAL_MACHINE \System\CurrentControlSet\Control\Citrix\Thinwire" -t "REG_DWORD" -v "MaxFbHeight" -d " MaxHeight" --force
<!--NeedCopy-->
Where MaxHeight
is a value between 1,024
and 16,384
.