Lync 2010 et Citrix XenDesktop 5
Posted by Teruin laurent sur mars 30, 2011
Citrix vient de publier un document sur la façon dont il faut déployer l’environnement Lync sur un environnement Xendesktop. Ceci couvre bien évidement les aspects voix et vidéo. ;-))
Voici l’article que vous pouvez trouver à l’adresse suivante http://support.citrix.com/article/CTX128831
« Delivering Microsoft Lync with XenDesktop 5
Document ID: CTX128831 / Created On: Mar 28, 2011 / Updated On: Mar 28, 2011
This article provides guidelines for configuring XenDesktop 5 to deliver Microsoft Lync (formerly Microsoft Office Communicator). Microsoft Lync is a unified communications client used with Microsoft Lync Server that provides instant messaging, voice chat and desktop video conferencing. Citrix XenDesktop with HDX RealTime allows users to communicate using the voice chat and video chat features of Microsoft Lync.
There are three scenarios where HDX RealTime is used with Lync:
- Voice chat using Voice-over-IP. This feature of Lync is much like using a telephone. It enables users to chat in real time using a headset or USB telephone connected to their computer or thin client.
- Video conferencing as an observer (voice-only participant). A user may choose to join in a video conference as a voice-only participant. The user can view the video conference and participate in the conversation but does not use a webcam.
- Video chat using a webcam.
This article describes how to get the best results from both products in these scenarios. It is split into two sections; the first section deals with any configuration changes needed to the XenDesktop 5 environment and the second section looks at Microsoft Lync itself.
For information on using XenApp 6 to deliver Microsoft Office Communicator, see CTX124655 – Best Practice: How to Configure XenApp 6 for Microsoft Office Communicator 2007 R2.
XenDesktop 5 Environment Configuration
The following configuration guidelines for XenDesktop can improve the user experience when using voice chat and/or video chat with Lync. The HDX Monitor should be used to confirm the configuration settings in effect.
Guidelines for Voice Chat
- If using a USB telephone on the LAN, then isochronous USB redirection over the CTXGUSB « Generic USB » virtual channel is recommended because both signaling and audio are involved.
- If using a headset, it is generally best to send the audio over the Bidirectional Audio virtual channel (CTXCAM, « Client Audio Mapping ») instead of using USB Redirection (CTXGUSB). This approach minimizes bandwidth consumption. Even if the webcam being used has a built-in microphone, it is generally best to use a headset with a microphone to avoid picking up ambient noise and generating echoes in the audio. Citrix recommends using a good quality headset with noise and echo cancellation. To use speakers and a microphone, you must use version 12.x or above of the Citrix Receiver’s online plug-in for Windows, because you need the echo cancellation feature introduced in that release. If you use the microphone in the webcam, note that there are two types of webcams; ones where the audio device is part of the webcam device and others where the audio device (USB logical arrangement) appears separately. Generally speaking, separate plug-in webcams have the audio and video USB functions combined, but laptop or integrated devices are often (but not always) separate devices. If the audio functionality is a separate USB device, you can redirect the audio separately using Bidirectional Audio.
- Configure Bidirectional Audio to use the Optimized-for-Speech audio codec (also known as Medium Quality). This codec was introduced in the Citrix Receiver for Windows’ 11.2 online plug-in and in the 11.100 Citrix Receiver for Linux. The bandwidth consumption with this codec is approximately 56 Kbps (28 kilobits per second in each direction). This is a low latency codec that is ideal for voice communications.
- Voice chat can be used over both LAN and WAN connections. On a WAN connection, audio quality depends on the latency, packet loss, and jitter on the connection. Citrix Branch Repeater should be used on connections to branch offices because it supports QoS for the ICA protocol, allowing the Audio virtual channel to be given priority. An enhancement to mitigate delays because of network congestion was introduced in XenDesktop 4 Virtual Desktop Agent Hotfix 2 (included with XenDesktop 4 Feature Pack 1). With this configuration, audio quality using the Optimized-for-Speech audio codec was subjectively evaluated by our Test engineers as Very Good on a WAN with five percent jitter, up to one percent packet loss (twice the industry standard recommendation for VoIP) and 150 milliseconds roundtrip latency (intercontinental/transoceanic).
- With XenDesktop 5, the Audio virtual channel priority defaults to Real-time (priority 0), also known as Very High. This is important to minimize latency in the audio path. Use the HDX Monitor to confirm that the Audio virtual channel priority is Real-time. If the priority of the Audio virtual channel is not Real-time, you can correct that using a registry setting.
- With XenDesktop 5, the Audio service (CtxAudioService.exe) on the Virtual Desktop Agent runs at Above Normal priority. Use the HDX Monitor to confirm that the Audio service is running at Above Normal priority. If the Audio service is not running at Above Normal priority, see « To change the priority of a running program », on the Microsoft Website.
Guidelines for Video Viewing
- To reduce the CPU load on the VDA platform (server) that results from viewing a video chat session, you can reduce the video display frame rate by setting the following registry entry: HKEY_LOCAL_MACHINE\Software\Citrix\PortICA\Thinwire MaxFramesPerSecond
The default value is 24 frames per second, but you can reduce that to 15 or 12 frames per second and still have a good video viewing experience. Note that this parameter applies to all server-rendered video, such as QuickTime and Silverlight movies, not to just video conferencing.
- Similarly, you might need to reduce XenDesktop’s maximum frame rate when delivering video to thin clients with relatively slow processors. Check CPU utilization on the user device. If it is pegging at 100 percent, you likely need to reduce the frame rate at which video is delivered.
- The quality of video viewing is also impacted by the image compression level used by Progressive Display. Progressive Display controls the quality of images that are dynamically changing, such as video. You can adjust the level of compression applied to dynamic images to find the optimal balance between video quality and bandwidth consumption. Higher compression degrades video quality but generates less data to send over the wire. This not only reduces network bandwidth consumption but can also reduce CPU load. Even though more CPU is used while compressing the images, the reduction in transmission data actually tends to reduce overall CPU consumption. Downstream video traffic typically consumes 800 Kilobits per second to 1.0 megabit per second of network bandwidth with Progressive Display enabled. See CTX124516 – How to Optimize HDX MediaStream Server-Rendered Video (Server-Rendered Multimedia).
Guidelines for Webcam Video Capture
- XenDesktop 5 features webcam video compression for Microsoft Lync / Office Communicator. This is supported by version 12.0 and above of the Citrix Receiver’s online plug-in for Windows. This optimization is preferable to « raw » isochronous USB direction because much less network bandwidth is consumed. Furthermore, this technology enables webcams to be used over a WAN connection, even at transoceanic latencies (200 millisecond roundtrip). Webcam video compression is enabled by default, as discussed in the online documentation. Typical upstream bandwidth consumption is 300 to 600 Kilobits per second.
- The Citrix Receiver for Linux also supports webcams, but only using isochronous USB Redirection. This technology is suitable for webcams that are LAN-connected to the data center, but cannot be used across a WAN connection.
- If using a webcam, Lync must execute directly on the Virtual Desktop Agent (VDA) platform. If Lync is hosted on XenApp 6 and delivered into the virtual desktop through ICA, a webcam cannot be used because double hop is not supported for webcams, regardless of whether using video webcam compression or isochronous USB redirection. Running Lync directly on the VDA platform also ensures the best audio quality for voice chat. So, Lync must be installed in the desktop image or (best practice) streamed to the XenDesktop virtual desktop. Further, Lync and Outlook must co-reside so they can exchange user presence information. Therefore, Outlook must also be installed in the desktop image or (best practice) streamed to the XenDesktop virtual desktop.
- The webcam requires a driver on the user device to successfully establish USB redirection. On Windows devices, the default driver is usually be suitable, but Citrix recommends obtaining the webcam manufacturer’s driver (latest version) because the default driver might not offer the video color space that the Citrix Receiver’s online plug-in for Windows 12.x is looking for, which could lead to unnecessarily high CPU consumption on the user device as a result of color space conversion. On Linux devices, obtaining a compatible driver is especially critical.
- Assign two virtual CPUs (vCPUs) to each virtual machine. Real-time video processing is data intensive and configuring two vCPUs reduces the thread switching latency. Note that having two vCPUs does not necessarily mean doubling the number of physical CPUs because physical CPUs can be shared across sessions. If you prefer not to assign two vCPUs to the virtual desktop, you might be able to reduce CPU load sufficiently by turning off the Citrix Gateway Protocol (CGP) used for Session Reliability. Be sure to monitor CPU utilization on the virtual machine to confirm that it does not peg at 100 percent.
- Advanced settings: Video Resolution
By default, Citrix Receiver’s online plug-in for Windows uses CIF resolution (352 x 288) to stream webcam video to the host. webcam video resolution can be adjusted by creating two DWORD values named « DefaultWidth » and « DefaultHeight » under HKEY_CURRENT_USER\Software\Citrix\HDXRealTime on the user device. Bear in mind, however, that Lync generally downscales to CIF resolution anyway, so increasing the video resolution over ICA is unlikely to make any visible difference and needlessly consumes additional bandwidth.
Single Server Scalability
- Server-side video processing has a significant impact on scalability because it is CPU intensive. You might find that a dual quad-core server supports a maximum of about 10 simultaneous webcam users. Therefore, if the number of webcam users who simultaneously participate in video conferences is high, Citrix suggests considering a value-add solution such as the one available from Avistar, a Citrix Technology Partner. The Avistar C3 Integrator for Citrix uses client-side media processing to maximize server scalability by offloading real-time processing to the user device.
Microsoft Lync Configuration
- In cases where USB Redirection must be used (such as with Linux devices) rather than the default of webcam video compression, network bandwidth consumption is highly dependent on the webcam and how it is configured (frame rate, resolution), and has been observed to vary from 2 megabits per second to 20 megabits per second or even more (typically 2 to 8 megabits per second). The following Microsoft Lync configuration tips can help you to minimize bandwidth consumption when using USB Redirection.
With some webcams, the Microsoft Lync Setup page displays configurable options. For example, with the Microsoft LifeCam VX-1000 there is a USB setting which impacts the bandwidth consumption.
- Microsoft Lync settings can be manipulated using an Admin Template. The settings below were found to be optimal during testing with a Logitech 9000 Webcam over USB Redirection:
Video Stream: 700 kilobits per second
Video Resolution: 640 by 480
- This configuration resulted in bandwidth consumption of 4 megabits per second peak between two Logitech 9000 Webcams. Of course, it is preferable avoid using USB Redirection because upstream bandwidth consumption is typically only 300 to 600 Kilobits per second when using the webcam video compression feature of XenDesktop.
- Adjusting the contrast of the webcam can reduce upstream traffic significantly. »