Lubuntu 20.04+ & XRDP = Working, but not the right session? - solution

As a continuation of https://discourse.lubuntu.me/t/lubuntu-20-10-xrdp-working-but-not-the-right-session I would like to add a solution, because the user “wxl” was unhelpful in that topic, it angered me enough to register and post a working solution, because as far as I can tell, noone on the Internet solved this issue.

The tail end of the /etc/xrd/startwm.sh file should look like this (comment out the two lines):

#test -x /etc/X11/Xsession && exec /etc/X11/Xsession
#exec /bin/sh /etc/X11/Xsession
unset DBUS_SESSION_BUS_ADDRESS
unset XDG_RUNTIME_DIR
. $HOME/.profile
env DESKTOP_SESSION=“Lubuntu” XDG_CONFIG_DIRS="/etc/xdg/xdg-Lubuntu:/etc/xdg:/etc:/usr/share" XDG_DATA_DIRS="/usr/share/Lubuntu:/usr/local/share:/usr/share:/var/lib/snapd/desktop" LXQT_DEFAULT_OPENBOX_CONFIG="/etc/xdg/xdg-Lubuntu/openbox/lxqt-rc.xml" /usr/bin/startlxqt

The reason for this is because Lubuntu Developers have hacked around issues with xdg/sddm/xorg:

https://phab.lubuntu.me/w/lubuntu-dev/xdg/

I haven’t tried this with Lubuntu 20.10, but it’s easy to check values of aforementioned variables and adjust them accordingly in the startwm.sh script.

20.10 is out of support now but it would be cool to try on 21.04.

I honestly don’t know if this was ever answered in the depths of the deep web but hey, at least you got it working. Bragging rights are yours my friend. :+1:

Thanks for sharing a solution. :grinning:

1 Like

20.04 is very much supported and that is the version I tested.

1 Like

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.