Simple steps to install xrdp and x11rdp on Ubuntu server.
To install xrdp and x11rdp on Ubuntu server, refer to the following steps but make sure that you are logged in as a root user.
sudo apt-get install xrdp
sudo apt-get build-dep xserver-xorg-core
sudo apt-get install gnome-session-fallback
apt-get install ubuntu-desktop
Create the new directory X11rdp
sudo mkdir /opt/X11rdp
Download the laytest x11rdp tar file from the http://server1.xrdp.org/xrdp/ website
tar -xvf x11rdp_xorg71.tar.gz
sudo sh buildx.sh /opt/X11rdp –with-fontdir=/usr/share/fonts/X11
Once compilation completed run the following command
Now we need to create the soft link for X11rdp binary in to /usr/bin directory
sudo ln -s /opt/X11rdp/bin/X11rdp /usr/bin/X11rdp
You can try to use :2 or :3 if :1 is already in use bu vnc ..
Create the .xsession file in your home directory and insert the following text in it
sleep 1 gnome-session –session=ubuntu-2d
If you receive the error about ubuntu-2d than refer to the following steps.
You can edit the file /etc/xrdp/startwm.sh as per your desktop requirement in RDP.
Simply add the following BOLD line from startwm.sh script .
if [ -r /etc/default/locale ]; then
export LANG LANGUAGE
echo gnome-session –session=gnome-fallback > ~/.xsession
You can also use the following parameter.
If you want to use GNOME Fallback (“GNOME Classic (no effects)”) insert the following in the startwm.sh file
- echo gnome-session –session=gnome-fallback > ~/.xsession
Or, to use Xfce (“Xubuntu Session”):
- echo xfce4-session > ~/.xsession
Or, to use LXDE (“Lubuntu Desktop”):
- echo lxsession -s Lubuntu -e LXDE > ~/.xsession
And it should work. Everytime you login to the remote-session the file .xsession will be created.