Citrix monitoring plugin

With this plugin you can monitor your Citrix servers

Introduction

We have chosen a number of modules "base" based on our experience in monitoring systems and the optimal parameters to diagnose potential bottlenecks on these servers. To extract the information is used:

Compatibility Matrix

System where it has been tested Windows Server 2008, Citrix XenApp 6
Systems on which it is expected to run Same system or higher

Depending on the type of operating system and language, the format of the performance counters may change and need to be adapted accordingly.

Prerequisites

The requirements to run the plugin are:

Configuration

Instalation

Copy the plugin in the plugin directory of agent or distributing by file collections. Same with the config files. The execution from the agent will be similar to this, but using the paths where the plugin and confs are installed. 

module_plugin "<powershell-path>\powershell.exe" -file C:\'<plugin-path>\pandora_citrix.ps1' -perf C:\'<conf-path>\counters_data.txt' -serv C:\'<conf-path>\services.txt’ -inc C:\'<conf-path>\counters_inc.txt' 2> error.log

If we want no monitor any perf counter or only a specific type, would have to carry out these executions:

module_plugin "<powershell-path>\powershell.exe" -file C:\'<plugin-path>\pandora_citrix.ps1' -perf C:\'<conf-path>\counters_data.txt' -serv C:\'<conf-path>\services.txt' 2> error.log
module_plugin "<powershell-path>\powershell.exe" -file C:\'<plugin-path>\pandora_ citrix.ps1' -perf none -serv C:\'<conf-path>\services.txt'   -inc C:\'<conf-path>\counters_inc.txt'' 2> error.log
module_plugin "<powershell-path>\powershell.exe" -file C:\'<plugin-path>\pandora_ citrix.ps1' -perf none -serv C:\'<conf-path>\services.txt' 2> error.log
module_plugin "<powershell-path>\powershell.exe" -file C:\'<plugin-path>\pandora_ citrix.ps1' -perf C:\'<conf-path5>\counters_data.txt' -inc C:\'<conf-path>\counters_inc.txt' 2> error.log

Configuration

First of all we have enabled the plugin execution from powershell For this, we must run this command in a powershell terminal: 

set-executionPolicy -Scope Process -ExecutionPolicy Bypass

or

set-executionPolicy RemoteSigned

If we run the plugin from the terminal and returns the information correctly, but if you execute it in from Pandora agent and returns no results, and in debug mode tells us that remote_signed not enabled, we should add the next module to be activated within the execution of the agent. This, you have to add only the first time, then stay enabled and we won´t have problems. 

module_begin 
module_name Remote_signed 
module_type generic_data_string 
module_exec powershell.exe –command set-executionPolicy -Scope Process -ExecutionPolicy bypass 
module_end

or

module_begin 
module_name Remote_signed 
module_type generic_data_string
module_exec powershell.exe -command set-executionPolicy RemoteSigned 
module_end

As we noted in the plugin implementation, it is accompanied by two or three configuration files, one with the name of the services and another two as the name of the performance counters to be monitored. At one we indicate the counters that we can see as generic_data type and in the second we will use the incremental type (generic_data_inc). In the event that the incremental type is not used should not be added at runtime. Each service, each performance counter should be on one line and if If you do not want monitor any counter or service, delete it from the list.

Configuration files examples 

Services.txt 

Citrix Independent Management Architecture
Citrix XML
Citrix XTE Server
Citrix CPU Utilization Management/Resource Management
Citrix CPU Utilization Management/User Session sync
Citrix CPU Utilization Management/CPU Rebalancer Services states
Citrix Print Manager
Citrix Virtual Memory Optimization
Citrix MF COM Remote Desktop Services/Terminal Services
Citrix WMI
Citrix Client Network
Citrix Streaming/Citrix Streaming Helper
Server
Netlogon
Remote Procedure Call (RPC)
Workstation
Print Spooler

Counters_data.txt 

\Processor(*)\% Processor Time
\System\Processor Queue Length
\Memory\Available Bytes
\Memory\Pages /sec
\Paging File\% Usage
\PhysicalDisk(_Total)\% Free Space
\LogicalDisk(_Total)\% Free Space
\LogicalDisk(_Total)\% Disk Time
\PhysicalDisk(_Total)\Current Disk Queue Length
\LogicalDisk(_Total)\Current Disk Queue Length
\LogicalDisk(_Total)\ Avg. Disk Sec/Read
\LogicalDisk(_Total)\ Avg. Disk Sec/Write
\LogicalDisk(_Total)\ Avg. Disk Sec/Transfer
\PhysicalDisk(_Total)\ Avg. Disk Sec/Read
\PhysicalDisk(_Total)\ Avg. Disk Sec/Write
\PhysicalDisk(_Total)\ Avg. Disk Sec/Transfer
\Citrix MetaFrame Presentation Server\Application Resolution Time (ms)
\Citrix MetaFrame Presentation Server\DataStore Connection Failure
\Citrix MetaFrame Presentation Server\Number of busy XML threads
\Citrix MetaFrame Presentation Server\Resolution WorkItem Queue Ready Count
\Citrix MetaFrame Presentation Server\WorkItem Queue Ready Count
\Citrix Licensing\Citrix Licensing - License Server Connection Failure
\Citrix Licensing\Citrix Licensing - Last Recorded License Check - Out Response Time
\Process(ImaSrv)\Private Bytes

Most Important Citrix Performance Counters

1.-  System Performance Counters (Citrix ) 

\Processor(*)\% Processor Time -> This counter is the main indicator of processor activity and shows the average percentage of time observed during the sampling interval. It is calculated by monitoring the time the service is idle and subtracting that value from 100%. The manufacturer indicates that between 80% and 90% over a 15-minute period should be set to Warning status and over 90% to Critical status.

\System\Processor Queue Length -> This is the current size in bytes of the virtual address space the process is using. The use of virtual address space does not necessarily imply corresponding use of either disk or main memory pages. Virtual space is finite, and the process can limit its ability to load libraries.

\Memory\Available Bytes -> Available memory indicates the amount of memory remaining after non-paged block allocation, paged block allocations, working sets, and all file system cache memory have taken their share. <30% RAM in warning state, <15% RAM in critical state.

\Memory\Pages /sec -> This is the speed at which pages are read or written to disk to resolve serious page faults. Warning status between 10 and 20, Critical > 20.

\Paging File\% Usage -> This is the percentage of the page file instance in use. Warning 40-70%, Critical > 70%.

\PhysicalDisk(_Total)\% Free Space -> This is the percentage of total usable space on the selected physical disk that is free. Critical <5%, Warning 5-10%.

\LogicalDisk(_Total)\% Free Space -> This is the percentage of total usable space on the selected logical disk that is free. Critical <5%, Warning 5-10%.

\LogicalDisk(_Total)\% Disk Time -> This indicates how busy the disk is. Warning > 70% consistently and Critical > 90%.

\PhysicalDisk(_Total)\Current Disk Queue Length -> This indicates the number of I/O operations waiting for the hard disk to become available. If the value here is greater than twice the number of spindles, it means that the disk itself may be the bottleneck. >=1 Warning, >=2 Critical.

\LogicalDisk(_Total)\Current Disk Queue Length -> Provides a primary measure of disk congestion. It is an indication of the number of transactions waiting to be processed. >=1 Warning, >=2 Consistently Critical, possibility of creating it with FF Threshold 2.

\LogicalDisk(_Total)\ Avg. Disk Sec/Read -> Shows the average time in seconds for a read from or to a disk. >= 15 ms Warning, >=20 ms Critical.

\LogicalDisk(_Total)\ Avg. Disk Sec/Write -> Shows the average time in seconds for a write from or to a disk. >= 15 ms Warning, >=20 ms Critical.

\LogicalDisk(_Total)\ Avg. Disk Sec/Transfer -> Shows the average time in seconds for a transfer from or to a disk. >= 15 ms Warning, >=20 ms Critical.

\PhysicalDisk(_Total)\ Avg. Disk Sec/Read -> Shows the average time in seconds for a read from or to a disk. >= 15 ms Warning, >=20 ms Critical.

\PhysicalDisk(_Total)\ Avg. Disk Sec/Write -> Shows the average time in seconds for a write from or to a disk. >= 15 ms Warning, >=20 ms Critical.

\PhysicalDisk(_Total)\ Avg. Disk Sec/Transfer -> Shows the average time in seconds for a transfer from or to a disk. >= 15 ms Warning, >=20 ms Critical.

\Network Interface (*)\ Bytes Total/sec -> Shows the speed at which the network adapter processes data bytes. This counter includes all data files and applications, as well as protocol information such as packet headers. 

Note: The names of all these counters may vary depending on the version and language of the OS used.

2.- XenApp Performance Counters

\Citrix MetaFrame Presentation Server\Application Resolution Time (ms) -> The time in milliseconds that resolution was completed. This is also the time required to determine the “least loaded” server during application launch. A baseline would need to be established in the environment in order to accurately set threshold values.

\Citrix MetaFrame Presentation Server\DataStore Connection Failure -> The number of minutes that the XenApp server has been disconnected from the data store. Thresholds should take into account events such as reboots and scheduled maintenance.

\Citrix MetaFrame Presentation Server\Number of busy XML threads -> The number of XML threads currently being processed. There are 16 worker threads in the Citrix XML Service. A count of 16 or more shows that XML requests are not being processed in a timely manner.

\Citrix MetaFrame Presentation Server\Resolution WorkItem Queue Ready Count -> The number of resolution work items (related to application launches) that are ready to be executed. A value greater than 0 indicates that requests are queued while IMA handles other requests.

\Citrix MetaFrame Presentation Server\WorkItem Queue Ready Count -> The number of work items that are ready to be executed. A value greater than 0 indicates that requests are queued while IMA handles other requests. This counter should not be greater than 1 for an extended period of time.

\Citrix Licensing\Citrix Licensing - License Server Connection Failure -> Shows the number of minutes that XenApp has been disconnected from the license server. Warning > 1 minute. > 1440 minutes Critical.

\Citrix Licensing\Citrix Licensing – Last Recorded License Check – Out Response Time  -> Shows the last recorded license check - out response time in milliseconds. A value greater than 5,000 milliseconds indicates a performance issue on the license server.

\Process(ImaSrv)\Private Bytes -> The current size in bytes of memory that this process (IMA) has allocated and cannot be shared with other processes.

If we want to monitor the % usage of the different processes that are running:
\Process(Process_Name)\% Processor Time -> % CPU in use by the process in question.

3.- Web Interface Performance Counters 

\ASP.NET\Request Queued -> The number of requests waiting to be processed by ASP. A baseline must be established in the environment in order to accurately set threshold values.

\ASP.NET\Request rejected -> The number of requests rejected because the request queue was full.

\ASP.NET\Request Current -> The current number of requests, both running and queued.

\ASP.NET\Request Execution Time -> The amount of time (in milliseconds) it took to execute the most recent request.

\Web Service\Concurrent Connections -> Current connections is the current number of connections established with the web service.

4.- Xen Desktop Performance Counters 

\Citrix Broker Service\Database Avg. Transaction Time -> Average time, in seconds, to execute a database transaction. A baseline must be established in the environment in order to accurately set threshold values.

\Citrix Broker Service\Database Connected -> Indicates whether this service is in contact with its database. (1 is connected, 0 is not connected).

\Citrix Broker Service\Database Transaction Errors/sec -> The rate at which database transactions are failing.

\Citrix Broker Service\Brokered Sessions -> The number of virtual desktop sessions brokered by the Citrix Service Broker.

\Citrix XML Service\Avg. Transaction Time -> The number of virtual desktop sessions brokered by the Citrix Service Broker.

5.- Other Citrix Performance Counters 

Depending on the OS version and language can change performance counters. For a complete list of ALL the counters that we have installed in this system we can run the following command and extract in a file as follows:

Get-Counter –listSet * | Select-Object -ExpandProperty Paths > counters.txt 
Once we have all the counters available in the system, we can copy all counters in a txt file that comes with the implementation of the plugin and it will create in PandoraFMS one module per token added.

\Citrix CPU Utilization Mgmt User\CPU Entitlement -> The percentage of CPU resource that Citrix CPU Utilization Management makes available to a user at a given time.

\Citrix CPU Utilization Mgmt User\CPU Reservation -> The percentage of total computer CPU resource reserved for a user, should that user require it.

\Citrix CPU Utilization Mgmt User\CPU Shares -> The proportion of CPU resource assigned to a user.

\Citrix CPU Utilization Mgmt User\CPU Usage -> The percentage of CPU resource consumed by a user at a given time, averaged over a few seconds.

\Citrix CPU Utilization Mgmt User\Long-term CPU Usage -> The percentage of CPU resource consumed by a user, averaged over a longer period than the CPU Usage counter.

\Citrix IMA Networking\Bytes Received/sec -> The inbound bytes per second.

\Citrix IMA Networking\Bytes Sent/sec -> The outbound bytes per second.

\Citrix IMA Networking\Network Connections -> The number of active IMA network connections to other IMA servers.

\Citrix Licensing\Average License Check-In Response Time (ms) -> The average license check-in response time in milliseconds.

\Citrix Licensing\Average License Check-Out Response Time (ms) -> The average license checkout response time in milliseconds.

\Citrix Licensing\Last Recorded License Check-In Response Time (ms) ->The last recorded license check-in response time in milliseconds.

\Citrix Licensing\Last Recorded License Check-Out Response Time (ms) -> The last recorded license check-out response time in milliseconds.

\Citrix Licensing\License Server Connection Failure -> The number of minutes that the XenApp server has been disconnected from the License Server.

\Citrix Licensing\Maximum License Check-In Response Time -> The maximum license check-in response time in milliseconds.

\Citrix Licensing\Maximum License Check-Out Response Time ->The maximum license check-out response time in milliseconds.

\Citrix MetaFrame Presentation Server\Application Enumeration/sec -> The number of application enumerations per second.

\Citrix MetaFrame Presentation Server\Application Resolution Time (ms) -> The time in milliseconds that a resolution took to complete.

\Citrix MetaFrame Presentation Server\Application Resolutions Failed/sec -> The number of application resolutions failed per second.

\Citrix MetaFrame Presentation Server\Application Resolutions/sec -> The number of resolutions completed per second.

\Citrix MetaFrame Presentation Server\Cumulative Server Load -> The combined processor utilization and connected XenApp user session loads for this server.

\Citrix MetaFrame Presentation Server\DataStore Connection Failure -> The number of minutes that the XenApp server has been disconnected from the data store.

\Citrix MetaFrame Presentation Server\DataStore bytes read -> The number of bytes read from the data store.

\Citrix MetaFrame Presentation Server\DataStore bytes read/sec -> The number of bytes of data store data read per second.

\Citrix MetaFrame Presentation Server\DataStore bytes written/sec -> The number of bytes of data store data written per second.

\Citrix MetaFrame Presentation Server\DataStore reads -> The number of times data was read from the data store.

\Citrix MetaFrame Presentation Server\DataStore reads/sec -> The number of times data was read from the data store per second.

\Citrix MetaFrame Presentation Server\DataStore writes/sec -> The number of times data was written to the data store per second.

\Citrix MetaFrame Presentation Server\DynamicStore bytes read/sec -> El número de bytes de datos del almacén dinámico leídox por segundo. The number of bytes of dynamic store data read per second.

\Citrix MetaFrame Presentation Server\DynamicStore bytes written/sec -> The number of bytes of dynamic store data written per second.

\Citrix MetaFrame Presentation Server\DynamicStore Gateway Update Count -> The number of dynamic store update packets sent to remote data collectors.

\Citrix MetaFrame Presentation Server\DynamicStore Gateway Update, Bytes Sent -> The number of bytes of data sent across gateways to remote data collectors.

\Citrix MetaFrame Presentation Server\DynamicStore Query Count -> The number of dynamic store queries that were performed.

\Citrix MetaFrame Presentation Server\DynamicStore Query Request, Bytes Received -> The number of bytes of data received in dynamic store query request packets.

\Citrix MetaFrame Presentation Server\DynamicStore Query Response, Bytes Sent -> The number of bytes of data sent in response to dynamic store queries.

\Citrix MetaFrame Presentation Server\DynamicStore reads/sec -> The number of times data was read from the dynamic store per second.

\Citrix MetaFrame Presentation Server\DynamicStore Update Bytes Received -> The number of bytes of data received in dynamic store update packets.

\Citrix MetaFrame Presentation Server\DynamicStore Update Packets Received -> The number of update packets received by the dynamic store.

\Citrix MetaFrame Presentation Server\DynamicStore Update Response Bytes Sent -> The number of bytes of data sent in response to dynamic store update packets.

\Citrix MetaFrame Presentation Server\DynamicStore writes/sec -> The number of times data was written to the dynamic store per second.

\Citrix MetaFrame Presentation Server\Filtered Application Enumerations/sec -> The number of filtered application enumerations per second.

\Citrix MetaFrame Presentation Server\ICA Roundtrip Latency Median -> The median time of ICA roundtrip latency for all sessions on the server.

\Citrix MetaFrame Presentation Server\LocalHostCache bytes read/sec -> The number of bytes of IMA local host cache data read per second.

\Citrix MetaFrame Presentation Server\LocalHostCache bytes written/sec -> The number of bytes of IMA local host cache data written per second.

\Citrix MetaFrame Presentation Server\LocalHostCache reads/sec -> The number of times data was read from the IMA local host cache per second.

\Citrix MetaFrame Presentation Server\LocalHostCache writes/sec -> The number of times data was written to the IMA local host cache per second.

\Citrix MetaFrame Presentation Server\Maximum number of XML threads -> The maximum number of threads allocated to service Web-based sessions since the server restarted.

\Citrix MetaFrame Presentation Server\Number of busy XML threads -> The number of busy threads.

\Citrix MetaFrame Presentation Server\Number of XML threads -> The number of threads allocated to service Web-based sessions.

\Citrix MetaFrame Presentation Server\Resolution WorkItem Queue Executing Count -> The number of resolution work items that are currently being executed.

\Citrix MetaFrame Presentation Server\Resolution WorkItem Queue Ready Count -> The number of resolution work items that are ready to be executed.

\Citrix MetaFrame Presentation Server\WorkItem Queue Executing Count -> The number of work items that are currently being executed.

\Citrix MetaFrame Presentation Server\WorkItem Queue Pending Count -> The number of work items that are not yet ready to be executed.

\Citrix MetaFrame Presentation Server\WorkItem Queue Ready Count -> The number of work items that are ready to be executed.

\Citrix MetaFrame Presentation Server\Zone Elections -> The number of zone elections. This value starts at zero each time the IMA Service starts and is incremented each time a zone election takes place.

\Citrix MetaFrame Presentation Server\Zone Elections Triggered ->The number of times a server triggers a zone election.

\Citrix MetaFrame Presentation Server\Zone Elections Won -> The number of times a server wins a zone election.

\ICA Session\Input Audio Bandwidth -> The bandwidth, measured in bps, used when playing sound in an ICA session.

\ICA Session\Input Clipboard Bandwidth -> The bandwidth, measured in bps, used when performing clipboard operations such as cut-and-paste between the ICA session and the local window.

\ICA Session\Input COM 1 Bandwidth -> The bandwidth, measured in bps, used when routing a print job through an ICA session that does not support a spooler to a client printer attached to the client COM 1 port.

\ICA Session\Input COM 2 Bandwidth -> The bandwidth, measured in bps, used when routing a print job through an ICA session that does not support a spooler to a client printer attached to the client COM 2 port.

\ICA Session\Input COM Bandwidth -> The bandwidth, measured in bps, used when sending data to the client COM port.

\ICA Session\Input Control Channel Bandwidth -> The bandwidth, measured in bps, used when executing LongCommandLine parameters of a published application.

\ICA Session\Input Drive Bandwidth -> The bandwidth, measured in bps, used when performing file operations between the client and server drives during an ICA session.

\ICA Session\Input Font Data Bandwidth -> The bandwidth, measured in bps, used when initiating font changes within a SpeedScreen-enabled ICA session.

\ICA Session\Input HDX Mediastream for Flash Data Bandwidth -> The bandwidth, measured in bps, used when streaming Flash data in an HDX-enabled session.

\ICA Session\Input Licensing Bandwidth -> The bandwidth, measured in bps, used to negotiate licensing during the session establishment phase. Often, no data for this counter is available, as this negotiation takes place before logon.

\ICA Session\Input LPT 1 Bandwidth -> The bandwidth on the virtual channel that prints to a client printer attached to the client LPT 1 port through an ICA session that does not support a spooler. This is measured in bps.

\ICA Session\Input LPT 2 Bandwidth -> The bandwidth on the virtual channel that prints to a client printer attached to the client LPT 2 port through an ICA session that does not support a spooler. This is measured in bps.

\ICA Session\Input Printer Bandwidth ->The bandwidth, measured in bps, used when printing to a client printer through a client that has print spooler support enabled.

\ICA Session\Input Seamless Bandwidth -> The bandwidth, measured in bps, used for published applications that are not embedded in a session window.

\ICA Session\Input Session Bandwidth-> The bandwidth, measured in bps, used from client to server for a session.

\ICA Session\Input Session Compression -> The compression ratio used from client to server for a session.

\ICA Session\Input Session Line Speed -> The line speed, measured in bps, used from client to server for a session.

\ICA Session\Input SpeedScreen Data Channel Bandwidth -> The bandwidth, measured in bps, used from client to server for data channel traffic.

\ICA Session\Input Text Echo Bandwidth -> The bandwidth, measured in bps, used for text echoing.

\ICA Session\Input ThinWire Bandwidth -> The bandwidth, measured in bps, used from client to server for ThinWire traffic.

\ICA Session\Latency - Last Recorded -> The last recorded latency measurement for the session.

\ICA Session\Latency - Session Average -> The average client latency over the lifetime of a session.

\ICA Session\Latency - Session Deviation -> The difference between the minimum and maximum measured latency values for a session.

\ICA Session\Output Audio Bandwidth -> The bandwidth, measured in bps, used for playing sound in an ICA session.

\ICA Session\Output Clipboard Bandwidth -> The bandwidth, measured in bps, used for clipboard operations such as cut-and-paste between the ICA session and the local window.

\ICA Session\Output COM 1 Bandwidth -> The bandwidth, measured in bps, used when routing a print job through an ICA session that does not support a spooler to a client printer attached to the client COM 1 port.

\ICA Session\Output COM 2 Bandwidth -> The bandwidth, measured in bps, used when routing a print job through an ICA session that does not support a spooler to a client printer attached to the client COM 2 port.

\ICA Session\Output COM Bandwidth -> The bandwidth, measured in bps, used when receiving data from the client COM port.

\ICA Session\Output Control Channel Bandwidth -> The bandwidth, measured in bps, used when executing LongCommandLine parameters of a published application.

\ICA Session\Output Drive Bandwidth -> The bandwidth, measured in bps, used when performing file operations between the client and server drives during an ICA session.

\ICA Session\Output Font Data Bandwidth -> The bandwidth, measured in bps, used when initiating font changes within a SpeedScreen-enabled ICA session.

\ICA Session\Output Licensing Bandwidth -> The bandwidth, measured in bps, used to negotiate licensing during the session establishment phase. Often, no data for this counter is available, as this negotiation takes place before logon.

\ICA Session\Output HDX Mediastream for Flash Data Bandwidth -> The bandwidth, measured in bps, used when streaming Flash data in an HDX-enabled session.

\ICA Session\Output LPT 1 Bandwidth -> The bandwidth, measured in bps, used when routing a print job through an ICA session that does not support a spooler to a client printer attached to the client LPT 1 port.

\ICA Session\Output LPT 2 Bandwidth -> The bandwidth, measured in bps, used when routing a print job through an ICA session that does not support a spooler to a client printer attached to the client LPT 2 port.

\ICA Session\Output Management Bandwidth -> The bandwidth, measured in bps, used when performing management functions.

\ICA Session\Output Printer Bandwidth -> The bandwidth, measured in bps, used when printing to a client printer through a client that has print spooler support enabled.

\ICA Session\Output Seamless Bandwidth -> The bandwidth, measured in bps, used for published applications that are not embedded in a session window.

\ICA Session\Output Session Bandwidth-> The bandwidth, measured in bps, used from server to client for a session.

\ICA Session\Output Session Compression -> The compression ratio used from server to client for a session.

\ICA Session\Output Session Line Speed -> The line speed, measured in bps, used from server to client for a session.

\ICA Session\Output SpeedScreen Data Channel Bandwidth -> The bandwidth, measured in bps, used from server to client for data channel traffic.

\ICA Session\Output Text Echo Bandwidth -> The bandwidth, measured in bps, used for text echoing.

\ICA Session\Output ThinWire Bandwidth -> The bandwidth, measured in bps, used from server to client for ThinWire traffic.

\ICA Session\Resource Shares -> The total number of shares used by the session.

Additional citrix monitoring

Network modules

We can remotely monitor the different ports that must be operative in our Citrix environment, here's the essential, but in the following catalog has details of all ports used by different components of Citrix 

http://support.citrix.com/content/dam/supportWS/kA460000000Cc9tCAC/Communication_Ports_ Used_By_Citrix.pdf

1. Controller,  Console Director and StoreFront

Ports 80 and/or 443 TCP 

2.- License Server 

Ports 7279, 27000, 8083, 8082 TCP 

It may do this through port monitoring server or network PandoraFMS through local modules from the same server or another we wanted to use for this purpose. 

Windows: 

module_begin
module_name Check port 80
module_type generic_proc
module_tcpcheck IP_Citrix_server
module_port 80
module_end

Linux:

module_begin
module_name Check port 80
module_type generic_proc
module_exec nmap IP_Citrix_server  | grep 80/tcp | awk '{print $2}' | grep open | wc -l
module_end
Monitoring Citrix Events

We can monitor any of the Citrix events writtent to the Event Log.

For them we can use module logevent type. 

module_begin 
module_name Event Citrix 
module_type async_string 
module_source Application  #Source (Application, System, or Security)
module_eventtype Information #Severity: Error, Information,
module_eventcode # Event ID 
module_description 
module_end

Event Codes generated by PVS

XenDesktop Broker LogEvents

XenDesktop VDA LogEvents

XenDesktop MCS LogEvents

Web Interface LogEvents

As an example some of the most important events are listed below. Recall that all these configurations should be added to the agent configuration file (pandora_agent.conf) 

module_begin
module_name EventControllerWrongUserAccount
module_description
module_type async_string
module_logevent module_source Application
module_eventcode 1000
module_end

module_begin
module_name EventBrokerThrottleStartupException
module_descriptio
nmodule_type async_string
module_logevent
module_source Application
module_eventcode 1004
module_end 

module_begin
module_name NoDatabaseConnectivity
module_description
module_type async_string
module_logevent
module_source Application
module_eventcode 1202
module_end 

module_begin
module_name Event_1388
module_description Citrix internal monitoring
module_type async_string
module_logevent
module_source Application
module_eventcode 1388
module_application HCAService
module_end 

module_begin
module_name Event_3621
module_description Citrix cannot connect SQL server
module_type async_string
module_logevent
module_source Application
module_eventtype Error
module_eventcode 3621
module_end 

module_begin
module_name Event_3961
module_description The Data Collector is out of memory, and the Dynamic Store data might be out of sync. Please elect a new Data Collector and make sure you have enough memory on the new Data Collector
module_type async_string
module_logevent
module_source System
module_eventcode 3961
module_end 

module_begin
module_name Event_5774
module_description Server goes to grace period (Not enough licences)
module_type async_string
module_logevent
module_source system
module_eventtype Error
module_eventcode 5774
module_application MetaFrame
module_end 

module_begin
module_name Event_9014
module_description Invalid licence
module_type async_string
module_logevent
module_source system
module_eventtype Error
module_eventcode 9014
module_application MetaFrame
module_end

Modules generated by the plugin

The plugin generates the following modules:

Service statuses

1.- XenApp Servers

2.- XenDesktop Services 

3.- Provisioning Services  

4.- Licensing Services 

5.- Web Interface Services 

Most important performance counters

Another thing we can monitor with this plugin is any of the performance counters we deem necessary. Below are the most important ones for detecting bottlenecks in Citrix and a list of all those available.