Citrix Sessions Test

Citrix Virtual Apps server securely delivers virtual applications and desktops to any device, over any network, empowering the delivery of a modern digital workspace. End users establish sessions to access applications and desktops hosted on the Citrix Virtual Apps server irrespective of the device’s operating system and interface. In Virtual Apps environment, maintaining session activity is critical for delivering an engaging and consistent user experience and ensuring best user productivity across any device. If users suffer session disconnects frequently or are unable to initialize / establish / terminate their sessions, it can adversely impact their productivity and their overall experience with the application/desktop delivery service. Moreover, if there are many idle and disconnected sessions on a server, they will unnecessarily hog precious server resources, causing critical business processes to contend for limited resources. This in turn can suspend/stall business-critical applications running on the server, thus delivering a sub-par experience to users. To prevent such anomalies, administrators should continuously track the status of sessions on the target Virtual Apps server, promptly capture sessions that are resource drainers, and rapidly initiate measures to control the resource usage of such sessions. This can be easily achieved using the Citrix Sessions test.

This test continuously monitors the sessions on the target Virtual Apps server and reports the count of sessions in different states. Detailed diagnostics reveal which sessions are in what state currently. Alerts are promptly sent out if sessions are in the 'Connecting' state for too long, or if there are any down, idle, or disconnected sessions on the server. This way, sessions that can potentially drain server resources and degrade user experience are brought to the attention of administrators. Besides warning administrators of resource contentions that idle/disconnected sessions can cause, the test also empowers them to avoid the probable resource shortage by initiating automated actions on these sessions. These actions and their outcome can be closely tracked, and errors (if any) can be investigated using detailed diagnostics.

Target of the test : Citrix Virtual Apps Server

Agent deploying the test : An internal agent

Outputs of the test : One set of results for the Citrix Virtual Apps Server that is to be monitored

Configurable parameters for the test
Parameter Description

Test period

How often should the test be executed.

Host

The host for which the test is to be configured.

Port

The port number at which the specified host listens to. By default, this is 1494.

Ignore Down Session IDs

By default, this parameter is set to 65536,65537,65538– these are nothing but the default ports at which the listener component listens. If any of these ports go down, then by default, this test will not count any of the sessions that failed when attempting to connect to that port as a Down session. You can override this default setting by adding more ports or by removing one/more existing ports.

Report Using Manager Time

By default, this flag is set to Yes. This indicates that the user login time displayed in the detailed diagnosis page for this test and in the Thin Client reports will be based on the eG manager's time zone by default. Set this flag to No if you want the login times displayed in the  detailed diagnosis page for this test and in the Thin Client reports to be based on the Citrix server’s local time.

Report By Domain Name

By default, this flag is set to Yes. This implies that by default, the detailed diagnosis of this test will display the domainname\username of each user session that logged out. This default setting ensures that administrators are able to quickly determine the domains to which the users who logged out belonged. You can set this flag to No if you want detailed diagnosis to display only the username of the users who logged out.

Automated Action Enabled

In multi-user environments like Citrix Virtual Apps/Desktops, server resources are shared by all user sessions on that server. In such environments therefore, it is important to ensure that users engaged in business-critical operations have the resources they need. A resource shortage can not only impair user productivity, but can also bring crucial business processes to a halt, and can severely degrade overall user experience with the application delivery service. To avoid such an outcome, administrators need to rapidly identify and intelligently manage those types of user sessions that consume resources unnecessarily - i.e., user sessions that are 'unproductive resource consumers'. This way, administrators can make sure that adequate resources are always available for carrying out important business tasks.

Idle sessions and disconnected sessions on a server are often considered to be a waste of valuable resources. If administrators are empowered to quickly identify these sessions and automatically eliminate them or limit their resource usage, they can:

  • Ensure that server resources are put to good business use;

  • Avoid resource contentions, and the resultant delay in delivery of business services;

  • Improve user productivity;

  • Assure users of an above-par experience with Citrix Virtual Apps

To enable administrators to achieve all of the above, eG Enterprise offers 'Automation Actions'. These actions are governed by the 'Automation Action Enabled' flag.

This flag, if enabled, automatically initiates user-configured actions on idle and disconnected sessions, so that they do not consume more resources than they should. Such an action can restrict the amount of resources used by these sessions, change the priority level of processes running in these sessions, and completely log off the sessions.

Note:

The 'Automation Action Enabled' parameters, once configured, will apply only to the chosen component. These settings will not be applied to other components even if the Apply to other components button is clicked in the Specific Test Configuration page.

Processes to Ignore

This parameter appears only if the Automated Action Enabled flag is set to Yes.

Administrators may want to allow a few critical processes - e.g., key operating system-level processes - unrestricted access to resources. This is because, applying resource usage limits to such critical processes might sometimes have unintended effects, including slow system responsiveness. To prevent such anomalies, administrators can use the Processes to ignore parameter.

Specify a comma-separated list of processes that should be excluded from automatic resource usage optimization. For example, your specification can be: Sophos UI,SearchApp.

Idle Sessions Action Enabled

This parameter appears only if the Automated Action Enabled flag is set to Yes.

Idle sessions on the target server are serious resource-drainers! Such sessions do not execute any operations, but consume resources significantly, thereby depriving critical sessions of the resources. To prevent this, administrators need to quickly capture idle sessions, and initiate measures to either terminate such sessions or cap their resource usage. This can be easily achieved using the Idle Sessions Action Enabled flag.

This flag, if enabled, ensures that a user-configured action is automatically triggered on sessions that are identified as 'idle'.

Idle Session Time Limit in Minutes

This parameter appears only if the Automated Action Enabled flag is set to Yes and the Idle Sessions Action Enabled flag is set to Yes.

Specify the duration (in minutes) of inactivity beyond which a session is considered to be “idle” by this test. By default, this parameter is set to 30 (minutes). This implies that by default, the test counts all sessions that have been inactive for over 30 minutes as idle sessions. Automated actions will be performed on such sessions only.

Idle Session Action

This parameter appears only if the Automated Action Enabled and Idle Sessions Action Enabled flags are set to Yes.

Here, you can choose either one or both actions that this test should automatically perform on an idle session. The options are as follows:

  • Change process priority to Below Normal - Typically, processes running at high priority will consume a considerable amount of server resources. Sometimes, this may cause low-priority processes to slow down, as they have to contend for limited CPU, memory, and I/O resources. If many high-prirority processes run in idle sessions, the overall resource consumption of such sessions will increase. As a result, critical processes running in active sessions will be denied access to resources. To prevent such problematic situations, administrators can use the Change process priority to Below Normal option. When this option is chosen, the priority level of high priority processes running in idle sessions will be bumped down and set to Below normal. This way, the resource consumption of idle sessions can be controlled.
  • Trim memory of the process - Choose this option if you want to trim/limit the memory usage of any process running in an idle session.

Note that the chosen action will not be triggered for the processes configured against the Processes to Ignore parameter.

Trim-to Memory Limit of the Process in MB

This parameter appears only if:

  • The Automated Action Enabled flag is set to Yes

  • Idle Sessions Action Enabled flag is set to Yes

  • The Trim memory of the process option is chosen from the Idle Session Action list

In this text box, specify the maximum amount of memory that any process running in an idle session can consume. By default, the value of this parameter is set to 10 MB. This implies that, by default, a process running in an idle session will not be allowed to consume more than 10 MB of memory, regardless of the memory capacity of the target server. This prevents wastage of memory resources by idle sessions, and also ensures that sessions running critical business applications do not run out of memory.

Disconnected Sessions Action Enabled

This parameter appears only if the Automated Action Enabled flag is set to Yes.

When a user abruptly disconnects his/her session, the applications started by the user will keep running on the target Virtual Apps server, consuming resources. This can lead to unnecessary resource consumption on the server. Hence, it is important to identify disconnected sessions and optimize their resource usage before they cause a serious resource contention on the server. This can be easily achieved using the Disconnected Sessions Action Enabled flag.

This flag, if enabled, ensures that user-configured actions are automatically performed on sessions that are identified as disconnected sessions.

Disconnected Session Time Limit in Minutes

This parameter appears only if the Automated Action Enabled and Disconnected Sessions Action Enabled flags are set to Yes.

This parameter enables administrators to specify how long a session should be disconnected from the target server for it to considered as a 'disconnected' session by this test. By default, this is set to 10 minutes. This means that any session that has remained disconnected from the server for 10 minutes and over, will be counted as a 'disconnected' session for the purpose of performing automated actions.

Disconnected Session Action

This parameter appears only if the Automated Action Enabled and Disconnected Sessions Action Enabled flags are set to Yes..

Here, you can choose the action that this test should automatically perform on a disconnected session. The recommended actions are:

  • Change process priority to Below Normal - Typically, processes running at high priority will consume a considerable amount of server resources. Sometimes, this may cause low-priority processes to slow down, as they have to contend for limited CPU, memory, and I/O resources. If many high-prirority processes run in disconnected sessions, the overall resource consumption of such sessions will increase. As a result, critical processes running in active sessions will be denied access to resources. To prevent such problematic situations, administrators can use the Change process priority to Below Normal option. When this option is chosen, the priority level of high priority processes running in disconnected sessions will be bumped down and set to Below normal. This way, the resource consumption of disconnected sessions can be controlled.
  • Logoff Session - When this option is selected, then, the disconnected session will be automatically logged off.

Note that the chosen action will not be triggered for the processes configured against the Processes to Ignore parameter.

DD Frequency

Refers to the frequency with which detailed diagnosis measures are to be generated for this test. The default is 1:1. This indicates that, by default, detailed measures will be generated every time this test runs, and also every time the test detects a problem. You can modify this frequency, if you so desire. Also, if you intend to disable the detailed diagnosis capability for this test, you can do so by specifying none against dd frequency.

Detailed Diagnosis

To make diagnosis more efficient and accurate, the eG Enterprise embeds an optional detailed diagnostic capability. With this capability, the eG agents can be configured to run detailed, more elaborate tests as and when specific problems are detected. To enable the detailed diagnosis capability of this test for a particular server, choose the On option. To disable the capability, click on the Off option.

The option to selectively enable/disable the detailed diagnosis capability will be available only if the following conditions are fulfilled:

  • The eG manager license should allow the detailed diagnosis capability
  • Both the normal and abnormal frequencies configured for the detailed diagnosis measures should not be 0.
Measurements made by the test
Measurement Description Measurement Unit Interpretation

Established sessions

Indicates the number of user sessions that are currently active on the target server.

Number

This measure gives an idea of the server workload in terms of active sessions. Tracking the number of active sessions with time, a Citrix administrator can obtain information that can help him/her plan the capacity of their Citrix environment. The detailed diagnosis capability, if enabled, lists the active and inactive sessions on the Citrix Virtual Apps server.

Idle sessions

Indicates the number of sessions that are initialized and are currently ready to accept connections.

Number

To optimize the performance of a server, two default (idle) sessions are initialized before any client connections are made. For performance reasons, the number of idle sessions should be less than ten. Note that this test does not differentiate between RDP and ICA sessions.

Connected sessions

Indicates the current number of sessions that are connected, but no user has logged on to the server.

Number

A consistent increase in the value of this measure could indicate that users are having trouble logging in. Further investigation may hence be required. Note that this test does not differentiate between RDP and ICA sessions.

Connecting sessions

Indicates the number of sessions that are in the process of connecting.

Number

A very high value for this measure indicates a problem with the session or connection. Note that this test does not differentiate between RDP and ICA sessions.

Disconnected sessions

Indicates the number of sessions from which users have disconnected, but which are still active and can be reconnected.

Number

Too many disconnected sessions running indefinitely on a Citrix Virtual Apps server cause excessive consumption of the server resources. To avoid this, a session limit is typically configured for disconnected sessions on the Citrix Virtual Apps server. When a session limit is reached for a disconnected session, the session ends, which permanently deletes it from the server. Note that this test does not differentiate between RDP and ICA sessions.

Listen sessions

Indicates the current number of sessions that are ready to accept connections.

Number

Note that this test does not differentiate between RDP and ICA sessions.

Shadow sessions

Indicates the current number of sessions that are remotely controlling other sessions.

Number

A non-zero value for this measure indicates the existence of shadow sessions that are allowed to view and control the user activity on another session. Such sessions help in troubleshooting/resolving problems with other sessions under their control.

Down sessions

Indicates the current number of sessions that could not be initialized or terminated.

Number

Ideally, the value of this measure should be 0.

By default, if sessions to any of these ports  – 65536, 65537, 65538 – could not be initialized or terminated, they will not be counted as a ‘down session’.

Init sessions

Indicates the current number of sessions that are initializing.

Number

A high value for this measure could indicate that many sessions are currently experiencing initialization problems.

Desktop sessions

Indicates the number of sessions that are established from desktops.

Number

 

Mobile sessions

Indicates the number of sessions that are established from mobile devices.

Number

 

Automation status

Indicates the current status of automation actions.

 

The values that this measure can report and their corresponding numeric values are discussed in the table above:

Measure value Numeric value
Not Required 1
Started 2
Running 3
Completed 4
Not Enabled 5
Failed 6

Note:

By default, this measure reports the Measure Values listed in the table above. In the graph of this measure however, the value of this measure is represented using their numeric equivalents only.

Use the detailed diagnosis of this measure to find out what automation action was triggered when the session was identified as idle or disconnected session.

The detailed diagnosis capability of the Established sessions measure, if enabled, lists the user sessions that are active on the Citrix Virtual Apps server. The sessions that were established through Rendezvous protocol is also identified and reported.

Figure 1 : The detailed diagnosis of the Established sessions measure of the Citrix Virtual Apps

The detailed diagnosis of the Automation status measure reveals the following details if Automation is enabled and running:

  • the automation actions that are performed on the idle/disconnected sessions during the current measurement period;

  • the details on errors, if any, encountered during execution of automation actions on the idle/disconnected sessions during the current measurement period;

  • the automation actions that were initiated in the previous measurement period and are completed in the current measurement period;

  • the details on errors, if any, reported during execution of automation actions were initiated in the previous measurement period and are completed in the current measurement period;

Figure 2 : The detailed diagnosis reported for the Automation status measure