xrdp with egfx pipeline testrun #2383
Replies: 46 comments 108 replies
|
this greatly reduces cpu usage under WSL |
|
Hi
im think SSL_write: I/O error is a main problem, i'm trying to search this error, but don't find working solution
if you catch this error and have a solution, tell me please |
|
I am having some issues with this that I don't really understand : I'm trying to connect with Remmina, in case that matters. The client just gets a black screen. |
|
Not sure if I did this right, but it's still really slow for me I connect with remmina and I can watch it paint the screen line by line (connected via 10Mbps connection) |
|
Here's a fun one, I migrated our production xRDP server to use egfx, with the following commands: We have both plasma and gnome installed (plasma is the default). after switching to egfx, the session was switched to gnome, even though .xsession and .xsessionrc are: |
|
How does this relate to dri3/glamor hardware acceleration in xrdp (that is working stable for me) ? #1029 |
|
Wow this is really impressive. Thanks for your work all. I'm happy to test out any changes that you want on my system to improve the stability. Should multi-monitor work already, or is this something that is known not to work yet? client: xrdp.log: |
|
This really speed xrdp connection up. Only issue I encounter is when I was remote connecting to my ubuntu computer using microsoft remote desktop in fullscreen mode. When the remote desktop software window lose focus and regain focus, the remote desktop freezes and I have to reconnect to regain control. |
|
Hi, Clean install , does not work at debian =) but still cannot install via apt-add-repository ppa:saxl/xrdp-egfx any ideas how to install that ? |
I believe DBUS is not working for snap apps with XRDP_USE_MULTISESSION. In my case this resulted in firefox (from snap) unable to open links ("Firefox is already running, but is not responding" popup). So for now I had to disable this feature. |
|
I'm a little puzzled at the moment. I'm running Endeavour OS (Arch-derived) and it's not entirely clear to me which features and settings are upstreamed. I'd love to have the nvidia acceleration and multi-session capabilities active; what's the correct way to proceed? 'Vanilla' xrdp is running fine, but is slow on the systems at the moment, with remmina as the client. Is there a summary / wiki overview of status, etc. somewhere to make it easy to get up to speed on the efforts? |
|
I am very intrigued. Would an aging Nvidia Quadro P2000 be able to accelerate this? |
|
Hello @akarl10 , first of all, thank you and the team so much for adding such significant improvements to xrdp with egfx features. I noticed that there have been some improvements and fixes related to efgx added to the project since the last build on the PPA. Could you update the ubuntu PPA with the latest code? I desperately want to try it out, but I don't know how to build the .deb package for Ubuntu, I did try some guides but I'm not able to make it work. Many thanks. |
|
Is it possible to build this on Alpine? |
|
I wanted to try this on an Google Cloud instance, as that would mean easy access to a variety of GPUs. Is this a dumb idea? Will the gains from the GPU be nullified by the latency to the cloud? (I'm sitting approximately 20ms away.) What would be a good GPU for this? The list of available ones is here Edit: I got this to work. Ubuntu 23, don't forget to install GNOME, went with a n1-standard-4 with a single NVIDIA T4 GPU core. Can't really tell if it's snappy or not. Input greatly appreciated. |
|
@akarl10 , hello! I've got some confusing issues when connecting to a Lubuntu 22.04 VM, and I'm not sure if it's just that I'm using an older version of the My RDP client is the "Windows app" on a Mac, which is just a renamed Microsoft RDP client. Inside the VM, the UFO test tells me I'm running at 60 FPS (well, 59 FPS). That's the result I'd expect. However, I can't change resolutions away from 1152x2048, and
The Mac "Windows app" doesn't have any options to force a refresh rate, and I can't figure out if it's even possible to set a desired resolution on the client. Is there a way I can force 60 Hz and or 4K resolution server side? |
|
Wonderful work. This is my number one package to install after a fresh Ubuntu installation (Even on 24.04)! One thing I noticed since ~2023: There is a quality/sharpness loss, even when connected at 3440 x 1440. (Intel UHD Graphics 630) I have all caching and compression settings in |
|
Is this the pull request that merged egfx? Just says |
|
Re: 4:4:4 and h264 support: It's my understanding that when we're using the Microsoft Remote Desktop app on a Mac (excuse me, "Windows.app," now), we're using h264, at 4:2:0? I think there's a registry tweak in Windows 11 to enable 4:4:4 over RDP, but I haven't tried it yet. I'm still stuck at 30 FPS in that Windows VM, even though I did the registry tweak that's supposed to enable 60 FPS over RDP. The default settings in my Lubuntu VM deliver 60 FPS to my client without a problem, even though the monitor I'm using on the client can't do more than 30 FPS (to my great annoyance; it's a 60 FPS monitor but just got old apparently). I'm not sure what the equivalent would be to specify/verify 4:4:4/best codec when connecting to an Ubuntu VM. Something in sesman.ini? |
|
Most of the bits from mainline merge have been merged to devel including most of the nvidia hack bits. It should be stable.
xrdp PRs, there are other PRs for xorgxrdp not listed here. |
|
Matt expressed interest in putting the latest libyami in our thirdparty for our use in xrdp. Just a bit of explanation of what libyami is. libyami is a helper library to make using libva easier. Intel and many other hardware companies out there are NOT giving up on libva. libva is very much still in active development. Intel just doesn't want to support libyami anymore. It's not just libyami, they archived MediaSDK too. https://github.com/intel/libyami |
|
I'm happy to look at that if we can get something working sooner. The risk of course is that we don't manage to get the port to libva sorted before libyami becomes unbuildable on modern systems. |
|
Hello, I'm sorry from the start if I'm asking something obvious here, but I've been baffled by all the information everywhere. Does EGFX pipeline actually work with NVidia GPUs for hardware acceleration like the original pipeline in xrdp works? I've managed to get NVidia GPU acceleration working on the xrdp package, but I've struggled with the egfx package... If the answer is yes, some small pointer to how to get it working would be awesome. |
|
This fork reduces cpu load greatly when running on the CPU. However, when enabling HW acceleration (XRDP_USE_ACCEL_ASSIST=1) my windows client (mstsc) shuts down complaining about a protocol error from the server. Couldn't find any good clue in the server logs. I am using a Sapphire Radeon RX 570 Nitro+ 8GB GPU and LXDE desktop. Is this a known issue? |
|
I just set up an Ubuntu 24.04 LTS VM with this xrdp package, and have it working with audio and GPU acceleration with an Intel i7-12700T iGPU. :) One odd thing I've noticed, though: Is this normal/expected behavior? I'm inclined to believe the reports from webGL aquarium and the ufo test--it seems unlikely they'd both lie in my favor. It makes more sense that Is this an actual problem, or just an xrandr issue? |
|
I've read some conflicting messages. Could you please confirm that xrdp-egfx only supports NVIDIA and not Intel graphics cards? Thanks |
|
Was there a signficant update for Noble-based systems in late October? Surprised to see an update in apt. |
|
For libva(Intel, AMD, etc) encoding I'm working on a library call libva_inf. It's partially working and once it's done we can enable hardware accel with libva. libva_inf is to replace lbyami_inf from the mainline_merge stuff. It uses libva directly and does not need libyami because libyami is archived. |
|
I did get Intel working with mainline_merge once upon a time, but I think what Jay said here is going to be better longer term. Intel redid their driver ecosystem shortly after I got it working :head_desk: |






Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
#1422 tracks the progress of the addition the new gfx pipeline.
news for ubuntu 24.04
since now most of this is upstream, I built a package based on devel for ubuntu 24.04. This package has software h264 only and no specific nvidia support. If you need that, it seems the 23.04 version still works under 24.04.
nvidia support is back again after being disabled for some time because of serve issues (to be exact starting with package version
1:0.10.80-20250813-1ubuntu1+0egfx2). It should enable automatically on new installations. For hardware H264 encoding enable the session variableXRDP_USE_ACCEL_ASSIST=1in the[SessionVariables]section insesman.iniA remaining issue with nvidia/lrandr and the plasma desktop is that the desktop does not resize to the real size, altough the windows itself can move everywhere.
In doubt apt purge xrdp-egfx xorgxrdp-egfx, remove /etc/xrdp, /etc/X11/xrdp and reinstall both packages.
when upgrading check if
/etc/xrdp/sesman.inicontainsSessionSockdirGroup=xrdpin the[Security]sectionEven though the pulseaudio module is still provided, pipewire-module-xrdp should be used instead
original post
This is a huge undertaking that has mostly be done by only two developers. @Nexarian is currently preparing merge requests, step by step, but this will take some time. @jsorg71 has done most of the groundwork.
I made some experiments for myself and to make it easer to test it on different platforms (intel gpu, amd gpu, nvidia gpu, virgl) I made a ubuntu ppa. This is still a moving target, but if someone wants to try out what xrdp will feel like in the (hopefully near) future here is my own instruction for my test setup
egfx xrdp installation
The patched version uses another name to prevent conflicts with the ubuntu version of xrdp
you may switch between them by uninstalling xrdp and installing xrdp-egfx.
Currently for jammy and kinetic only. Based on https://github.com/Nexarian/xrdp/commits/mainline_merge and https://github.com/Nexarian/xorgxrdp/commits/mainline_merge
all commands are running in a root session. In doubt simply put a sudo in front of every line or start a root shell with
sudo -i or sudo -s (what you prefer)
clean install
apt-add-repository ppa:saxl/xrdp-egfx apt install xrdp-egfx xorgxrdp-egfx #optional apt install pulseaudio-module-xrdpI higly recommend replacing configuration files with the new provided ones if asked.
You should reboot now since a udev rule is added that allows anyone to use /dev/dri/renderD*. This is needed for non-nvidia 3d accelleration
The specific file is
/usr/lib/udev/rules.d/90-xorgxrdp-dri.rulesAlso xorgxrdp-egfx has a postinstall script that reconfigures sesman.ini for nvidia gpu if needed. Consequiently a restart of that service might be needed.
swap from xrdp to xrdp-egfx
apt purge xrdp xorgxrdp apt-add-repository ppa:saxl/xrdp-egfx apt install xrdp-egfx xorgxrdp-egfx #optional apt install pulseaudio-module-xrdpswap back to xrdp from xrdp-egfx
tweaks
desktop selection
The desktop that gets launched is configured in
/etc/xrdp/sesman.iniLook for the line
you can put every desktop listed in
/usr/share/xsessions. Just put the name wihout .desktopIf you want to use this feature on a per user basis you could put something like
in ~/.profile
nvidia h264 hardware encoding
if you have a nvidia gpu you might enable hardware h264 encoding by editing
/etc/xrdp/sesman.inisimply change the line at the near bottom from
# XRDP_USE_HELPER=1toXRDP_USE_HELPER=1multisession support and more consistent pulseaudio
you might try enabling multisession support. This way reduces possible conflicts if you somehow are logged in twice or more (ex. locally and via xrdp)
Currently to get audio in Ubuntu Kinetic you need this (or at least it is the easies way)
Essentially this makes a "subsession" in /run/user/UID/, spawns a matching dbus, pulseaudio and pipewire (that uses pulseaudio)
simply change the line at the near bottom of
/etc/xrdp/sesman.inifrom# XRDP_USE_MULTISESSION=1toXRDP_USE_MULTISESSION=1Should work with both plasma and gnome.
check out https://github.com/matt335672/nest-systemd-user
verify that it's working
gfx pipeline
You should immediatly see a big performance improvement when connecting with a modern rdp client.
mstsc should connect with gfx h264 while stock freerdp in ubuntu repositories only uses gfx rfx progressive
what codec is used you will see in
/var/log/xrdp.log. Look for a line that saysor
desktop 3d and video
For 3d check if
glxinfo | grep rendereroutputs your gpu. In a plasma desktop session your taskbar's background should be transparent with a blur effect.For video check the output of
vainfo.Note that ubuntu jammy's version of libva2 has a issue with intel gpu's that has been fixed since in kinetic (see intel/libva#582). As a workaround you might set an appropriate
LIBVA_DRIVER_NAME=in/etc/xrdp/sesman.iniin the[SessionVariables]section.client side considerations
to get h264 in freerdp you must recompile it with ffmpeg enabled (ubuntu has disabled it because ffmpeg is not in main).
you should also get better performance when connecting to a windows rdp server
other changes from ubuntu xrdp
startwm.sh
changed if x-session-manager is gnome-session and start with the correct environment so that the ubuntu shell is started instead of the default gnome one
some modifications for my own XRDP_USE_MULTISESSION idea
polkit
a polkit (
/etc/polkit-1/localauthority/10-vendor.d/01-xrdp-rules.pkla) rule is added. This prevents popups for network and color managementissues
nvidia uses lrandr since standard randr will not work there. This one is incomplete and for plasma this means the desktop shell does not respond to size changes. At least it shows the correct output in xrandr
the gfx rfx pro codec makes a "scanline" effect.

snap does not work fully in XRDP_USE_MULTISESSION mode (mainly sound and maybe open file dialog issues)
flatpak works tough
All reactions