Citrix Receiver for Linux on Raspberry Pi 2 using Raspbian Jessie

Pi_+_Debian_+_Receiver_200This is a follow on post to my original post, Citrix Receiver for Linux on Raspberry Pi 2 using Raspbian Wheezy. Now that the Jessie based version of Raspbian is available, it simplifies some of the steps necessary to deploy the Citrix Receiver for Linux on a Raspberry Pi 2.

As before I’ll present this as a step by step guide to hopefully make it easy to follow.

The Goal

As stated in the original post “Allow the standard Citrix Receiver for Linux to run unmodified on a Raspberry Pi 2. e.g. 13.x Linux Receiver for ARMHF“. Well Raspbian Jessie release this is now possible. Though to get the best out of it you’ll still need to make some changes.

Deployment and Configuration

Step 0: Raspbian configuration

Before going any further, you’ll want to expand the filesystem to avoid running out of space on your root volume. This can lead to your Raspberry Pi failing to boot and instead just showing a black screen with a flashing cursor at the top.

  • Run sudo raspi-config and select option “1 Expand Filesystem“. After this is completed you need to reboot.

Another setting you will probably want to change is to ensure the network is up before the device completes the boot process; otherwise there is a risk that you may try to use the Receiver (or any other application that requires a network connection) before the network is ready, resulting in errors being displayed. This too is configured via rasp-config

  • Run sudo raspi-config and select option “4 Wait for Network at Boot“, then select the option for “Slow Wait for network connection before completing boot“. On your next boot, you may notice it takes a little longer, ensuring the network is up before it starts the X Server.

Not if you are using wireless network adapter, you’ll want to ensure you’ve configured that correctly before you switch to the slow boot option.

Step 1: Download and Install Citrix Receiver for Linux ARM (ARMHF)

The Citrix Receiver has a number of package dependencies, some required some recommended. I’d recommend you use gdebi to install the packages as it will find and install the dependent packages and therefore simplify the setup. So if you don’t have it installed already run the command: sudo apt-get install gdebi

Also ensure you download the ARMHF packages and not the ARMEL versions.

  • Download the Debian (.deb) packages of Citrix Receiver for Linux (ARMHF) and the (optional) USB Support Package from citrix.com.
  • Install the Receiver: sudo gdebi icaclient_13.2.0.322243_armhf.deb
  • (optional) Install the USB Support package: sudo gdebi ctxusb_2.5.322243_armhf.deb

Step 2: Optimise Performance

Ensure you are using a suitable PSU, 5V 2A (2000mA). If you see a rainbow square appearing on the top right of your screen, this indicates insufficient power and will impact the performance of your Raspberry Pi.

If you review the OEM guide you’ll realise you can monitor quite a bit about the client side performance from setting some WFICA_OPTS before launching the Receiver. You can do this via the command: export WFICA_OPTS="-rm Dcdjfresot" (see the section “Monitor real-time performance” in the Citrix Receiver for Linux OEM’s Reference Guide for more information on what each of these values do).

You can also check some of the session metrics using Citrix HDX Monitor.

HDXMonitor_HomeHDXMonitor_Thinwire_Advanced

Benchmark_Pi2For my test I connected to a XenApp 7.6 Desktop at 1600×1200 and ran a 720p video using VLC. The frame rates and CPU usage values quoted are the average during video playback. The initial rate achieved before any optimisation was 6.8 FPS @ 45% CPU usage. After all the optimisations below are applied, including the Pi2 preset overclock; there was a 178% improvement to 19.1 FPS @ 32% CPU usage.

2.1 Increase the depth of the FrameBuffer
  • Edit the file /boot/config.txt
  • You can place this change anywhere in the file, but it makes sense beneath the entries for framebuffer_height, which are commented out by default
  • Add the line: framebuffer_depth=32
    • Note: According to elinux.org setting the framebuffer_depth > 16 will also need: framebuffer_ignore_alpha=1. My basic testing didn’t observe any difference, so perhaps this has been resolved in more recent releases? 
  • Save and exit
  • Reboot your Pi (sudo reboot)
2.2 Switch to using libjpeg62-turbo

The ARM processor in the Pi 2 supports some extensions to accelerate certain operations, called NEON. Intel has MMX and SSE2. Using these extensions libjpeg-turbo claims a 2x-4x speed improvement. The Citrix Receiver configuration needs to be modified a little to take advantage of this. Once again we have to use the unstable branch to access the required packages.

  • Switch package sources to the unstable branch. Follow the steps in 1.1 (above)
  • Install the libjpeg76-turbo package: sudo apt-get update && sudo apt-get install libjpeg62-turbo
  • Repeat step 1.5 from above to revert the changes to the repository locations
  • The Citrix receiver works through possible jpeg decoders it can use. On my Pi 2 it was using ctxjpeg_fb_8.so as /usr/lib/arm-linux-gnueabihf/libjpeg.so.8 was present, however this isn’t the accelerated version. So we need to rename this so that the Citrix Receiver doesn’t try and use the version 8 fallback.
    • sudo mv /opt/Citrix/ICAClient/lib/ctxjpeg_fb_8.so /opt/Citrix/ICAClient/lib/ctxjpeg_fb_8.so.DO_NOT_USE
  • Now the Citrix Receiver will use ctxjpeg_fb.so which is linked to the newly installed libjpeg62-turbo library.
2.3 Disable H264 Graphics Mode on Citrix Receiver

A side effect of increasing the size of the frame buffer (step 5.1), is that by default connections will now switch to H264 mode. However this won’t give the best experience on a Raspberry Pi, so we’ll want to disable this for all connections

  • Edit: /opt/Citrix/ICAClient/config/module.ini
  • Under the section for: [WFClient]
  • Add the line: H264Enabled=False
  • Save the file
2.4 Disable Multimedia Receiver on Citrix Receiver

When you make a connection to your XenApp/XenDesktop Server you may want to try playing some video content. Citrix has a feature (HDX MediaStream aka RAVE) which can redirect video to be played using client side resources rather than playing it server side. The Pi, however doesn’t work well with this. So we’ll want to render our video server side.

  • Edit: /opt/Citrix/ICAClient/config/module.ini
  • Under the section for: [ICA 3.0]
  • Edit the line for: VirtualDriver =
  • Remove the entry for: MultiMedia
  • Save the file
2.5 Implement Thinwire+ (aka Project Snowball)

 

The Thinwire+ feature is now available in XenApp/XenDesktop 7.6 Feature Pack 3, see: https://www.citrix.com/blogs/2015/10/01/feature-pack-3-for-xenapp-and-xendesktop-7-6-is-now-available/

Step 3: Additional Performance Optimisations (optional)

The raspi-config utility provides some simple steps to try out various levels over overclocking your Pi. Online you can buy heatsinks and cooling fans if you feel the need to push the limits of your Pi and go beyond some of the standard overclock settings.

raspi-config-overclock-settings

Setting overclock setting to the “Pi2” preset:

  • Increase the maximum clock speed (arm_freq) by 11% to 1000MHz.(The min remains 600Mhz)
  • Increases the core (GPU) frequency (core_freq) by 100% to 500MHz
  • Increases the memory frequency (sdram_freq) by 25% to 500MHz
  • Increases the over_voltage to 2, effectively providing an additional 2 x 0.025V to the base 1.2V CPU voltage. This is generally needed to balance the increase power draw from increasing clock frequencies.

In the quick test I performed, I didn’t noticed any significant difference in the performance or interactivity of my session. But my test environment (e.g. Home HP MicroServer) might be resource constrained here.

Final Performance: 19.1 FPS (+179%) @ 32% CPU (-30%) – Using Citrix Compatibility Graphics mode with snowball private

Additional Information

75 thoughts on “Citrix Receiver for Linux on Raspberry Pi 2 using Raspbian Jessie

  1. Even with Jessie, the turbo library and all, the performance still appears to be better with the on-board H.264 decoding.

  2. Hi, Martin: Yes, I just saw that and that’s a great way to have an instant option to compare or to go with one or the other when the circumstances make one preferable over the other.
    -=Tobias

  3. Hello, I followed your steps on the Pi2 and installed the Receiver. We have Windows 10 on a VM inside our network, which is accessable from my Mac, iPhone, Chromebooks and other laptops within the business. However, the Pi2 doesn’t launch the receiver. The circular thing shows, and then nothing happens. When I try to access via browser, we’re able to access the storefront, but when I go to launch desktop or the published apps, again, nothing launches. Any ideas?

    1. Do you have another VDA OS to try connected to from the Pi. I’m curious if this is a problem with the Pi connecting to any session or just Windows 10?

  4. We only have Windows 10 at the moment, however, I don’t believe its the Windows OS causing issues. When I enter the server address when launching the Citrix Receiver, I get the following error “Your account cannot be added using this server address. Make sure you entered it correctly. An SSL connection to the server couldn’t be established because the server’s certificate was not trusted.”

    1. For simple testing if you can try and use the non-SSL PNAgent site that will confirm if the basic connections can be made. I suspect you are hitting a problem with Storefront and you’ll need to get the right SSL certificates in to the right location on the client. I think this is covered is the Citrix docs.

  5. One issue that has emerged is an odd periodic delay in the video delivery – a slight, reular pause every 3 or 4 seconds – when tapping into a virtual instance like XenApp running on top of XenServer and viewing in full-frame mode at high definition. We don’t see this when connecting to Physical hardware with the VDA installed, only with Virtual Machines In other words, we are wondering if there is some type of obscure bug in the VM Networking stack that only shows up when the desktop is delivering H.264 video. We see the same issue with the Intel NUC range, DE3815 Thin Canyon, i3 and i5. John Nicholls (ThinLinX) reported this to Citrix R&D several weeks ago and they just said:

    “This is an issue with graphics and thinwire. We could check the graphics mode and further analyze from there.”

    There has been no feedback since then. t also, interestingly, does not occur if you install the Citrix VDA on a PC, which allows you to then to connect to Storefront and then connect to the PC; this is nicely explained in:
    https://www.citrix.com/blogs/2015/01/07/introducing-a-stand-alone-vda-for-xendesktop-and-xenapp-7-6/

    Why would this not show the issue compared to a virtualized version of XenApp? In any case, I really hope Citrix R&D can help fix this and perhaps you, Martin, or someone else can provide some additional support.

    Best regards,
    -=Tobias

    1. Hi Tobias, I’m sure you understand that my personal blog is not intended to circumvent the official support processes at Citrix. But I’ll share some thoughts. When you introduce a hypervisor you’ve added a layer between the OS and the hardware there are many places here that could start to be potential sources of inducing problems. Historically we’ve seen issues with NIC offload capabilities, some fixed with different drivers and/or firmware, others just by disabling these features. Also when you are running on a hypervisor you’re now sharing resources that your RemotePC has all resources dedicated to it. Finally I assume your XenApp/Hypervisor server is a different hardware spec to your RemotePC scenario? I know our HDX performance team have found scenarios where the Server isn’t powerful enough to delivery high graphics at the desired frame rate. A more powerful server may behave better, but it may not make for a scalable solution. I assume you’re monitoring performance metrics VDA side and at the hypervisor level to determine if there is a resource usage spike or drop at the time of the pause.

      Our of interest can you define the HD content (resolution and frame rate) since this? Does this only happen when using client side H264 offloading? What about other graphics modes? They may (or may not) be able to sustain same high frame rate, but are they consistently lower or do they have the same pause behaviour?

  6. Hi Martin,

    We see the same pause issue with the RPi2, Intel NUC range, DE3815 Thin Canyon, i3 and i5. My test environment is XenDesktop and XenApp 7.6, I am using Windows Server 2012 R2 and HyperV. I have a Window7 and Windows 8.1 VM running also about 20 Apps running from XenApp on a Server 2012 R2 VM. I also have an i5 NUC running Windows 8.1 with the VDA installed on it. I never see any pauses on the Physical hardware only the VMs. The problem only shows up when the H.264 hardware decoder is being used. You should see this issue yourself if you force H.264 mode on the RPi2. Funny thing is I do not have any pauses with XenServer running VDI in a Box.

    Thanks

    John

    1. Hi John, are you able to try a Server 2012R2 VM on a different hypervisor. Since you say VDI in a box is OK on XenServer. This could come down to a hypervisor/driver issue with Hyper-V?

      1. Our XenApp environment, BTW, is a Dell R720 running XenServer 6.5 SP1 and XenApp 7.6 FP3 running under Windows 2012 R2, with 16 VCPUs and plenty of memory, and no other active XenApp sessions (it’s exclusively for testing) and fully patched. In our case, there is no Hyper-V involved whatsoever. There is also no lack of compute/memory/network resources. The same was experience under XenApp 7.6 FP2. There is something in the application virtualization layer that seems to bring about this oddity and since it’s seen only with higher resolution, seems also related to buffering, perhaps in its timing or how the buffers are flushed and replenished. I can only speculate, not having the depth of knowledge of what goes on under the hood.

  7. Hi Guys,

    we use the Raspi2 with Wheezy(also tested with jessie) with Citrix Receiver 13.2 as Thin Clients, but we have the Problem, that the Citrix Window just closes without a reason. No entrys in any logs. It happens completely randomly. It seems that nothing triggers the crash… We are using XenApp6.5 btw.

    Does anyone got a hint how to fix this?

    1. Have you tried the Receiver 13.2.1 version? We do not seen any instability issues with it. Also, do you have some sort of session timeout set, perhaps?

      1. Yes I have also tried with this last version.
        It’s the same problem that the others.
        Do you know how to configure the timeout with Jessie ?

  8. We did nothing with any timeout settings — not sure if something like that even exists. Did you make any changes to the CPU/memory settings and configure everything else according to the instructions above?

    1. I follow step by step all the instructions. I tried with both Jessie and Wheezy but it’s the same problem. I don’t know where that’s coming from …

      1. So there isn’t anything specific you are doing when it crashes/exits? Are you interacting with it, or is it left idle and you find the session gone unexpectedly? On the server do you see is the session reported as disconnected? Could there be any underlying network issues?

  9. Hi martin,

    I’ve updated ctxh264pi to support raspbian jessie(kernel 4.1).

    I also have change video_render from egl_render to reduce mouse move lag.

    In my demo(VDA 7.6 FP3 + Windows10 / VDA7.6 + Win7 + GRID)
    I can play 1080p video smoothly. And I can’t noticed mouse move lag
    I think it has most significent efforts.

    I’ve updated binary to support raspbian jessie(kernel 4.1).
    a simple install script have included.

    Manual Step:
    1.Because of kernel 4.1 change, add dtparam=mailbox to /boot/config.txt
    2.update xorg which support hwcursor.
    3.copy 99-fbturbo.conf to /usr/share/X11/xorg.conf.d/
    4.copy bcm_init.so to /lib/
    5.copy ctxh264.so to /opt/Citrix/ICAClient/lib/

    Known Issues:
    1.audio may have lag.

    Binary:
    https://github.com/luyi1888/ctxh264_pi/releases/tag/v0.5

    Source Code:
    https://github.com/luyi1888/ctxh264_pi

    PS:
    It can support 1080p 60fps if you overlock gpu_freq to 400.

  10. Hello, Yi:
    Thanks for all your updates and efforts!
    Do you see any of the periodic short delays in the video discussed above every 3 or 4 seconds with full-frame playback? There has not been evidence of audio lag before in this release so that’s curious.
    Best regards,
    -=Tobias

    1. Yeah. I get this problem in my Win7 demo.
      You can enable aero to avoid this. Enable aero can also solve a lot of strange problems.
      Or just upgrade to Win10 + VDA 7.6 FP3.

  11. A lot of aero features are deprecated in Windows 8.X. The hotfix XS65ESP1010 provides a newer Windows 10 template for XenDesktop. The older technical preview didn’t seem to work with the Xentools installation, so maybe this one is better. We’ll give it a try.

  12. Just tried this with a Win 10 VM under XA/XD 7.6 FP3 and while better, the lag was still evident. The XA is running as a VM under XenServer 6.5 SP1 — how is your XA instance configured, Yi? Is it virtualized and if so, under what?

    1. My XA doesn’t published any multimedia program. I do all test on XD.
      In last 3 days, I play video several times on Win7+GRID/Win10.
      I can see Win7 + GRID is better than Win10. But it also have the same lag.
      So the problem is existed on both Thinwire and Thinwire Advanced.
      I can see this problem in both WAN and LAN. WAN will have longer delay than LAN. Maybe this problem related to network?
      My demo has Netscaler 8200 act as Netscaler Gateway. I don’t know if direct connect to VM will better?

      1. Hi, Yi:
        The tests are also all run using XenDesktop, but some of the apps come from XenApp (that make use of the GRID). The same setup works without delays for other devices, such as Dell/Wyse thin clients and physical PCs with the same server and network configurations, so the server/network environment is not the issue. This is in a very fast, LAN and so network delays are definitely not he problem. John Nicholls reports this delay with the NUC i5, so it’s not just the Pi that is affected. With Citrix VDA, the pause does not show up plus it doesn’t appear using VDI-in-a-Box, Thus it seems it may be a subtle issue with the Receiver specific to certain clients. That is evidently the only common factor. You see it even in smaller frames, so it’s not just at full-frame resolution that the problem is evident. Interestingly, this delay was not seen in the very early Pi 1 (ARMv6) configuration that Muhammad Dawood first released.
        -=Tobias

        1. This is a real mystery, in my case it seems to be Network related at least with my testing XenDesktop and XenApp 7.3 running on Server 2012 R2. The issue only occurs if I am connecting to a VM running the VDA, if I install the Citrix VDA on a physical box running Windows 8.1 I don’t see any problems.

          On my Network, I see the same pauses / freezes when using a Windows version of Receiver running on a i5 NUC

          I carried out a test using a i5 NUC running Windows 8.1 and Windows Citrix receiver running on that i5 NUC, (launched from the Chromium Web Browser). I see the same issues, but overall performance is not as good as our TLXOS running on the same hardware, I see lockups / Freezes and not just when when playing flash, disconnects with immediate reconnect a few seconds later, almost seems like a Network issue to me…

        2. No network issues for us — everything is on high-speed LANs for our tests, so other than the occasional delay inherent in youtube videos, the only issue we see with just about any sort of video regardless of size or resolution or image format is a slight delay every few seconds that looks like a buffering or synchronization issue. This shows up also for any virtualized XenDesktop and XenApp instances and is subtle but definitely there. With exactly the same hardware and network back end, it does not show up for the Dell/Wyse thin clients, running the same XD/XA 7.6 FP3. So, I think that vindicates the network, and points more towards something specific to the Citrix Receiver as to how it handles connectivity to these specific hardware configurations. We have not tried yet upping the graphics memory to 400 MB as you suggested, Yi, but with previous tests, this made no difference at all and the delays still showed up.

          I do wish Citrix would be willing to take a closer look at this, as it may be something present inherently in the Receiver, just too slight to see in most cases. It was not evident in the Armv6 Pi B/B+ version, so clearly, something is different and since it’s in both the Intel NUC i5 and Pi 2 chipsets, it’s clearly not unique to a single hardware platform. If it’s a bug, it should be addressed in general, and specifically for those of us who have been putting a lot of energy into these alternative platforms that hold so much promise as XenDesktop/XenApp thin clients.

        3. Yi:
          We tested with both Windows 8.1 and Windows 10 and definitely evident in both. We don’t use Windows 7 any more, so there was no sense on going a step backward. We have not done any testing at this point with Linux VMs.
          -=Tobias

        4. Sorry, I was referring to the Pi 2 test VMs. The Dell/Wyse clients run the same VM Windows VMs, but their internal OS is WTOS 8.0 and more recently. 8.1, and WTOS (Wyse Thin Operating System) is proprietary and near as I can tell all written into firmware. I have honestly no idea what WTOS is developed with or based on.

  13. Hello,

    Thanks for your post it’s clear and very usefull.

    i have installed a raspbian with noobs 1.5 and i successfully installed the citrix client.

    And i successfully run ica file with /opt/Citrix/ICAClient/wfica.sh to run a publish desktop.

    But i want to run this automaticly when rapsberry boot and automaticly shutdown raspberry when user log off publish desktop.

    You want that is possible ?

    thx

      1. i have try some example but it doesn’t work.
        however my command line work in terminal (/opt/Citrix/ICAClient/wfica.sh icafile.ica)
        even i have a warning about security on dll file.

        i speak about autologon enabled, what is it ?
        how can i bypass security warning ?

        another post speak about two lib : (https://www.raspberrypi.org/forums/viewtopic.php?f=66&t=123014)

        sudo apt-get install libwebkit-dev
        sudo apt-get install libxerces-c-dev

        you know what is it ?

        Thanks

  14. Firstly you may have to add the path to the ICA file. But I’m not sure. You mention a security warning, what does the message say?

    My reference to autologon is with respect to how you have configured raspbian, it can boot to a logon screen, it can boot and autologon to a terminal and it can be configured to boot autologon and start the X Server.

    The other post which makes references to the webkit dependancies, this should already be installed if a) you downloaded the icaclient and not icaclientWeb and b) used gdebi to the install the package.

    If you are trying to create a thin client, you may want to look at what ThinLinx have to offer: http://www.thinlinx.us/ it can be configured to do what you want (I believe) and also has a management server to manage your clients. It’s not free, but it doesn’t look too expensive.

    1. Hello thanks for your answer.

      I have add the all path of wfica.sh and the ica file but it dosen’t work.

      My secrurity warning is in french but it say that my ica.file can compromise the security with the line :

      Indeed i want to build thin client but just with Citrix Client ans VNC server

      Thanks

    2. Stephane, I’m unclear as to which bit isn’t working. I don’t have a setup available right now which accepts direct ICA file connections.
      I was able to confirm that if I edit: /etc/xdg/lxsession/LXDE-pi/autostart
      and add a line: @/opt/Citrix/ICAClient/wfica.sh /home/pi/test.ica
      (before the screensaver line) that upon logon the client launches and attempts to connect.

      Note if you have a local user autostart file: ~/.config/lxsession/LXDE-pi/autostart then this is used instead of the one in /etc.

      It would appear from looking online that some people believe that having both autostarts means both are run, however according to http://wiki.lxde.org/en/LXSession If both files are present, only the entries in the local file will be executed.

      If your problem is still with the security message, then I think I need to see a screenshot or similar of the error I can then ask the developers what triggers this to be displayed. You can tweet me the image, or if you contact me via the contact web form we setup an email exchange.

      1. Hi Martin,

        Thanks for your answer.

        Two things,

        First i have understand why i have the security message, it is due to configuration line in ica file. In fact i have made this ica file with windows client and at botton i have the line beelow, after i have delete it the security message disappear

        [Encrypt]
        DriverNameWin32=PDCRYPTN.DLL
        DriverNameWin16=PDCRYPTW.DLL
        [Compress]
        DriverName=PDCOMP.DLL
        DriverNameWin16=PDCOMPW.DLL
        DriverNameWin32=PDCOMPN.DLL

        Second, i have understand why the citrix client doesn’t start. In reality it start, but just for 30 seconds if i don’t connect to windows session. And how i use vnc to see the screen of PI2 it is all teim too late … sorry.

        Now, how can i increase the time to open session of citrix remote desktop connection ?

        Beelow my ICA file can you check if it is correct ?

        And more it is possible to shutdown PI2 automaticly if citrix client (/opt/Citrix/ICAClient/wfica.sh /home/pi/test.ica) is ended ?

        Finally it is possible to connect two screen/display 1080p ?
        I just want to use desktop with office application don’t video.

        Thaknk very much

        My ICA FIie

        [Encoding]
        InputEncoding = ISO8859_1
        [WFClient]
        Version=2
        PersistentCacheEnabled=On
        PersistentCachePath=
        PersistentCacheSize=8192
        ProxyType=Auto
        HttpBrowserAddress=10.0.3.41:8080
        ConnectionBar=0
        CPMAllowed=Off
        CDMAllowed=Off

        [ApplicationServers]
        Bureau SCWNCIT013=

        [Bureau SCWNCIT013]
        Address=Bureau SCWNCIT013
        InitialProgram=#Bureau SCWNCIT013
        CGPAddress=*:2598
        ClientAudio=Off
        DesiredColor=8
        DesiredHRes = 4294967295
        DesiredVRes = 4294967295
        DesiredWinType=7
        TWIMode = False
        KeyboardTimer = 0
        MouseTimer = 0
        ConnectionBar=0
        Username=
        Domain=
        TransportDriver=TCP/IP
        WinStationDriver=ICA 3.0
        BrowserProtocol=HTTPonTCP
        Compress=On
        EncryptionLevelSession=Encrypt

        1. A good source of information on the values in the ICA file can be found here: http://www.ingmarverheij.com/the-citrix-ica-file-explained-and-demystified/

          The Compress setting should be fine. If you have removed the encrypt section then it should still use basic encryption, which is actually what you are asking for. Obviously using a higher level of security is preferable.

          With respect to the session ending, I wonder if this is really that the session taking to long to start, perhaps best to add an & to the end of the line you’re calling so that the client runs as a background process. Or is it that the session has started and it’s sitting at a Windows logon prompt for 30 seconds waiting for a user to enter some credentials. If that’s the case, I think you may be approaching this wrong, and instead want to use selfservice and have the user connect and authenticate to that and have them launch their desktop/application from there. Otherwise the server will potentially be using a lot of resources for users that are not actually connected.

          As for shutting down the pi on session exit, that I think you need more investigation into how lxsession works and if you can get it to run just the citrix app, then on exit perform a shutdown. Or have a script that tracks the existence of Citrix process and then shutsdown on detecting the exit.

          As to your final point about multiple displays. As you know the Pi only has a single video output, there is/was a project to use the GPIO pins to create a secondary VGA port, but I’m unsure how much work that would be to get to work properly. There are also USB display adapters, these are probably a better solution if you can find suitable drivers, this I think will be the challenge. I did stumble across one forum post where someone had created a mutlimonitor solution on a Pi specifically for a Citrix client, but when they tried to use it, the Citrix Client crashed. It’s unclear what specifically the problem was and if it was something Citrix could fix. I think for now multi-monitor Pi, it somewhat of a stretch goal.

        2. Seems like the easiest way to get a second display would be to network to a second RPI and map the video to its HDMI output. The one company I was aware of that was looking at a GPIO-based module, but that was apparently abandoned. A USB-based option might be hard to get to work well, especially given the USB2 restriction, but then again, hat might be adequate. I’d be interested, Stephane, if you look further nto any such additional display option.

        3. Hi,

          After many tests i have changed my approach.

          Now i use my Citrix WebInterface for XenApp 6.5.

          Indeed i installed Iceweasel which can start automaticly ICA file when i connected to the WebInterface and i start it automaticly with PI desktop in full screen, with add-on Fullscreen 1.0.4, on WebInterface URL.

          But i have again a warning message about security in /tmp/launch.ica with CDMAllowaed=On, while it is not configured in application properties in Citrix Appcenter.

          Apart from this warning, im near the goal, the only thing missing is the desktop streched on two desktop.

          Have you another idea ?

          Thanks
          Happy Xmas

        4. Glad you’re making progress. I looked into the possibility of using a USB video adapter to get a second screen, but the YouTube video I watched showed significantly different performance between the two screens. I think for now the Pi is really limited to single monitor deployments only.

        5. Would it not be possible to redirect an additional video session to a second RPI2 and use it to support a second monitor on its HDMI port? Seems like that would be an inexpensive option to support another monitor that should be possible.
          -=Tobias

        6. Tobias, I think the idea of having multiple Pi to drive multiple displays is likely to the only way to support it, in fact the Pi Wall http://www.piwall.co.uk/ does just this with what appears to be a master control Pi followed by a Pi per display. Now of course displaying content is one thing getting handling input and mouse position across multiple devices and doing this in a way that is seamless to applications like Citrix Receiver is the key, but also the biggest challenge.

          Maybe someone can solve this, certainly beyond my abilities.

        7. Have you tried WideScreen 2560 x 1080 21:9 ?

          Have you a tricks to reduce /root volume because i want to make an image master but some SD card are differents and too small.

          Thanks

        8. I think the key to building a small image is to start with the most basic version you can get and just add what you need to deliver the desktop/applications you need. I’ve personally not experimented with trying to reduce the size down. I’ve ended up with numerous 8GB and 16GB cards as the cost of these was low, I’ve not considered going smaller. Though I accept if you were trying to create many of these, then the cost might be more of a factor.

          As for 2560×1080, that’s not one of the standard modes the RPi supports (per: http://elinux.org/RPiconfig), though it may be possible with custom HDMI settings, there are a few topics on this, such as: https://www.raspberrypi.org/forums/viewtopic.php?f=28&t=119849
          To clarify, I’ve not tried that widescreen resolution myself, as I don’t have access to the hardware necessary.

  15. Hi,
    I’ve just installed Receiver for Linux 13.3 (ARM HF) from Dec 14, 2015 on a fresh 2015-11-21-raspbian-jessie.img and after rebooting my Pi2 won’t start anymore. I only see a blinking cursor. I’ve tried several times now.
    Any idea?

      1. No nothing. Thanks for the fast reply. First I’ve tried without gdebi and thought that caused the issue. But then I flashed the raspbian image to my sd card again and tried with gdebi. Same result. It’s the latest Receiver (13.3) though. I’ll try 13.2 now.

        1. Ok I had the same problem after installing gdebi and the Citrix Receiver 13.3. However this was down to the / volume being full. If you run raspi-config and expand the file system, then reboot, it will recover.

  16. I’ve updated the guide to add a couple of steps around the initial configuration which will hopefully help prevent others from falling foul of this disk space issue.

    Udo, can you confirm that fixing the filesystem space problems addresses your problem too.

  17. Hi guys,
    is this supposed to work on a Raspberry Pi 1 (running Jessie) as well?
    I’ve installed the latest Receiver ARM HF package but after that selfservice does not start.
    Regards
    Udo

  18. Hey Guys,
    I’m currently trying this out for work. At work we use a http url and not a https url for citrix receiver. Has anyone worked out how to use a http url? In windows I have to use regedit to get it to work that way. Not too sure how to make it work in linux though.
    Any help would be much appreciated.

      1. Thanks heaps Guys. That all worked and Citrix works really smoothly without me modifying the Raspberry Pi 2. It actually works smoother with Citrix, then the HP Thin clients we have.

        I have another question. How do I get Citrix to autostart?

        1. Jon, you should look at the lxsession autostart file: /etc/xdg/lxsession/LXDE-pi/autostart or in the users home directory: ~/.config/lxsession/LXDE-pi/autostart
          You can add a line with the full path to the program you wish to run, this just needs to be prefixed by a @ sign.

          It would appear from looking online that some people believe that having both autostarts means both are run, however according to http://wiki.lxde.org/en/LXSession If both files are present, only the entries in the local file will be executed.

        2. Hello

          I have do it :

          sudo nano ~/.config/lxsession/LXDE-pi/autostart

          @/opt/Citrix/ICAClient/wfica.sh /home/pi/Downloads/Bureau.ica

          before the line

          @xscreensaver -no-splash

          You can use this ica template :

          [Encoding]
          InputEncoding = ISO8859_1
          [WFClient]
          Version=2
          HttpBrowserAddress=
          ConnectionBar=0
          CPMAllowed=Off
          CDMAllowed=Off

          [ApplicationServers]
          Bureau=

          [Bureau]
          Address=Bureau
          InitialProgram=#Bureau
          CGPAddress=*:2598
          ClientAudio=Off
          DesiredColor=8
          DesiredHRes = 4294967295
          DesiredVRes = 4294967295
          DesiredWinType=7
          TWIMode = False
          KeyboardTimer = 0
          MouseTimer = 0
          ConnectionBar=0
          Username=
          Domain=
          ClearPassword=
          TransportDriver=TCP/IP
          WinStationDriver=ICA 3.0
          BrowserProtocol=HTTPonTCP
          Compress=On
          EncryptionLevelSession=Encrypt

    1. In this day and age where security plays a vital role in communications and connectivity, there is no excuse to not use the https protocol whenever possible!

      1. Thanks for the reply guys.
        Yes I’m using the PNAgent site. I’ll give it another try tomorrow as I don’t have the Pi 2 with me today. I’ll have to get back to you 🙂

  19. Pingback: Cloud Evangelist
  20. I have a server running UnRaid 6.1.9, I’m running a Windows 10 VM on that server. I want to use my Raspberry Pi 2 as a thin client to connect to my Windows 10 VM. I have found some tools but all have terrible video performance. When I want to stream GoPro video full HD it is not usable. But with your solution I’m confident that it could works. Unfortunatly, I can’t figure out what I need to install on my server or on my Windows 10 VM.

    So could you help me on what I have to setup to allow me to use my Raspberry Pi as thin client.

    Thanks

    1. By certificates I assume you mean getting the certs in place to be able to connect to StoreFront via https. Is that right? If so I’ll write up another post trying to explain this. If it’s something else, please clarify.

  21. Following your instructions, I managed to get Citrix Receiver installed. Thanks! I found that I needed to run sudo apt-get update && sudo apt-get dist-upgrade and also add the IceWeazel certs:

    sudo ln -s /usr/share/ca-certificates/mozilla/* /opt/Citrix/ICAClient/keystore/cacerts/
    sudo c_rehash /opt/Citrix/ICAClient/keystore/cacerts/

    I did find that email based discovery for CR config failed, although it works fine on other platforms.

    For the performance optimizations in Step 2 and 3, which are relevant for RPi3?

    Thanks!

    1. For the RPi3 all of Step 2 is still relevant. Step 4, overclocking, well that’s going to be a little dependent on your RPi3 cooling, power supply etc, so purely down to choice. I’d start without overclocking to see if it meets your needs 1st.

Leave a Reply