Installation of the Log Analytics Agent

The installation is very simple. It only takes two steps to achieve the goal: Install the agent and configure your OMS Log Analytics workspace. To make it easy for anyone, here are the two steps as a detailed guide.

Prerequisites

If you have an Azure subscription, you can use the ITPC-LogAnalyticsAgent for free in the current version as it is. Just set up the partner id 1101651 (DPOR) in this Azure subscription. Why is this important? Developing the agent and the views is time intensive. I prefer to offer this project for free. Therefore, it helps me if you connect your Azure subscription with the partner id of my employer to be visible to Microsoft as a performing partner.

You can use the agent with Citrix Sites version 7.x and maybe above. The agent is tested on Windows Server 2008R2/2012R2/2016 and Windows 7-10 (64 Bit only). If you use it on a VDI, the total network transmission performance and logon duration are not monitored.

Create Log Analytics workspace in Azure

  1. Login into your Azure portal: https://portal.azure.com
  2. Click: New, Intelligence and Analytics, Log Analytics to configure your new workspace.
    Give your workspace a world wide unique name, select a subscription and a resource group. The pricing tier should be "Standalone" (payed per Gbyte upload). You can also start with "Free" and switch to "Standalone" later. Be aware: The free tier purges collected data after 7 days and there is an upload limit of 500 Mbyte per day.
  3. Go to your workspace by clicking OMS Portal. In your portal navigate to Settings, Connected Sources, Windows Servers and note the workspace id and the primary key. You will need both later to configure the agents running on your worker.

Deploy the agent to one worker

  1. Unzip your download and copy the folder ITPC-LogAnalyticsAgent to e.g. C:\Program Files of one of your Citrix Workers.
  2. Make sure that only trusted admins can open this folder. Use the Windows NTFS security settings.

Configure the agent

  1. Modify the file ITPC-LogAnalyticsAgent.exe.config in your program file folder and configure the following entries in the appSettings section:
    1. CustomerId - enter your workspace id (mandatory)
    2. SharedKey - enter your primary key of your workspace (mandatory)
    3. UpdateIntervalInSeconds - time in seconds the agent sends data to your workspace (default: 60)
    4. SimulateDataSend - 0: data will be sent to Azure; 1: data will not be sent (default: 0)
    5. ProxyUri - proxy URL, if you use a web proxy
    6. ProxyNeedAuthentication - 0: proxy doesn't need a logon; 1: logon to a proxy is requiered (default: 0)
    7. ProxyUserName - user name for a proxy authentication
    8. ProxyPassword - password for a proxy authentication
    9. UseHashesInsteadUserNames - 0: user names will be used for analytics; 1: user names will be hashed / pseudo anonymization (default: 0)

Test the connection to your workspace

  1. Open a command line with administrative privileges. Navigate to the ITPC-LogAnalyticsAgent folder.
  2. Run: ITPC-LogAnalyticsAgent.exe -test
  3. The agent will start and send test data to the configured workspace. If everything works, you shouldn't see any errors after Entering test mode:
  4. Data collection for a short test starts if you run ITPC-LogAnalyticsAgent.exe. You can stop the collection with CTRL+C.
  5. Tip: Start the data collection and wait before you import the OMS views into Log Analytics. For the first time, it takes some hours to see the data in the Log Analytics workspace. Be patient: After the data scheme is created and the first data are indexed it works fast.

Deploy the agent to all workers

  1. To install the agent as a scheduled task (the agent will starts after a reboot or from the scheduled task app) open a command line with administrative privileges.
  2. Navigate to the ITPC-LogAnalyticsAgent folder.
  3. Run: ITPC-LogAnalyticsAgent.exe -install
  4. Copy the configured ITPC-LogAnalyticsAgent folder to all other worker and install the agent with the step before (or do this once on a PVS golden image or a software distribution).

Import the predefined views to your workspace

  1. Open your OMS workspace in a web browser.
  2. Click on the tile View Designer, Import and navigate on one worker to your ITPC-LogAnalyticsAgent folder.
  3. Import all .omsview files form the RDS or Citrix folder (regarding your environment).

You are ready now. For the first time, it takes some hours to see the data in Log Analytics. Be patient: When the data scheme is created and the first data are indexed it works fast.

Next step: Go to the download!

Download