Ubuntu 14.10 – KDE as alternative Desktop for XRDP sessions


Hello World,

In our previous post about XRDP, we have described how to install the LXQT desktop environment and have it working for XRDP remote connections.  We decided to write the post about LXQT because some of our users were requesting such post. This post is also based on a user request.  Recently, a user posted a comment about using KDE desktop environment in combination with XRDP software solution.

If you want to use another desktop environment than LXQT with your XRDP session, please have a look at our previous posts :

Note :

These posts are also available for Ubuntu 14.04.  We recommend to read the posts mentioned above as they contain the most recent information.

So, if you are ready, let’st install XRDP pacakge and use the LXQT as default desktop environment during your XRDP remote session.

Installing XRDP and KDE on your Ubuntu machine

Install XRDP Package from Ubuntu Repository

In this post, we will be installing the standard xrdp package from the Ubuntu Repository. In order to perform the installation of the xrdp package, you will login into your ubuntu 14.10 machine.

Using the Dash button, in the search box, type Terminal

Click on Picture for Better Resolution

Click on the terminal icon and the Terminal console will open

In the Terminal, type the following command

sudo apt-get install xrdp

You will be prompted for your password

Click on Picture for Better Resolution

You will be then informed about the package size. To proceed with the installation, press Y

Click on Picture for Better Resolution

Wait for the completion

When done, you need to install an alternate desktop environment. In our scenario, we are using lxde

Installing the KDE Desktop environment

I had to google a bit to see how we could install the KDE Desktop environment on a Ubuntu machine. I have seen complex command to be execute. At the end, we have simply decided to install the kubuntu desktop on our ubuntu machine (which contains the kde desktop). To perform this operation, we have simply issued the following commands, from a terminal console

  • sudo apt-get update
  • sudo apt-get install kubuntu-desktop

When issuing the first command, you might be prompted for the password (you are using sudo..). Provide the password and wait for the installation to complete.  This process might take some time.

Checking the KDE Desktop interface 

After the installation is been performed, you will need to check that the desktop has been installed correctly and it’s available on the machine.  To ensure that, simply logoff from your current desktop environment and go back to the login interface of ubuntu.

At the  login page, click on the Ubuntu logo in the login box.

Click on Picture for Better Resolution

after clicking, you should see a menu similar to the one on the screenshot where you can select a list of alternate desktop interfaces installed on your system

Click on Picture for Better Resolution

In our scenario, we will select the option KDE Plasma Workspace. When you have made your choice, you can enter username and password and login into your Ubuntu machine.  The KDE desktop interface should look like something captured on the screenshot below

Click on Picture for Better Resolution


Configure xrdp to use KDE desktop environment

At this stage, you have to configure your Ubuntu machine in order for xrdp to know that the KDE desktop will be used instead of the Unity. To configure this, from the terminal console, you will issue the following command

echo startkde >~/.xsession


Click on Picture for Better Resolution

Restart the xrdp service by issuing the following command

sudo service xrdp restart

Click on Picture for Better Resolution


Note :

This configuration will only allow one user to connect to XRDP and use the KDE desktop environment. This would be the user for which you have updated the xsession file.  If you need to have all of your users to perform remote desktop session through XRDP and to load the LXQT desktop environment, you should update your /etc/startwm.sh file.   We have described the process in the following post

Configuring the XRDP keyboard layout 

By default, the xrdp login screen is set to use an english keyboard layout.  If you are using another keyboard layout, you would need to configure the XRDP server in order to use your preferred keyboard layout.  The procedure below will update the keyboard layout used during the xrdp sessions. In order to configure XRDP keyboard layout (the , perform the following actions :

Step 1 : You go to the /etc/xrdp directory

Step 2 : you issue the command setxkbmap -layout <%your layout%> to define which keyboard map/layout to use

Step 3 : create a copy of the km-0409.ini file into the same directory. It seems that this is the default file used by xrdp to define the keyboard layout. You will need to use sudo in order to be able to write into the directory

Step 4 : Check that you have a backup of your file by typing the dir or ls command

Step 5 : update the file by issuing the following command sudo xrdp-genkeymap km-0409.ini

Test your xrdp connection

At this stage, you should be able to perform a remote desktop session to your ubuntu machine and have the LXQT desktop loaded.  To test your xrdp solution, find the ip address of your linux machine (or use the name if you have DNS Infrastructure in place). To find the ip address, issue the command

hostname -I

Click on Picture for Better Resolution

Now go to your windows machine, start remote Desktop client and enter the ip address/name of your ubuntu machine

Click on Picture for Better Resolution

You should see then the login screen of xrdp presented to you. Remember that by default the keyboard layout is set to English.  If you have not changed your XRDP keyboard settings (see procedure above) to your preferred keyboard layout, you will need to ensure that the password entered is following the english keyboard layout.

Click on Picture for Better Resolution

Enter your username and password and Press OK

You will see a dialog box showing the login process

Click on Picture for Better Resolution

If everything is configured correctly,you should see your KDE desktop loading and you should be able to perform you work through this desktop environment.

Click on Picture for Better Resolution

Reconnect to the same session throug xrdp

If you are using Ubuntu 14.10 or if you are using the XRDP package 0.6.1-1, there is no need to perform any additional configuration in order to reconnect to the same session.

Click on Picture for Better Resolution

As described in our previous posts, the xrdp packages have been updated and now out-of-th-box, you can indeed reconnect to the same sessioin.  To have more information about that, please check the following posts :

Final Notes

You did it !  You have installed KDE desktop and now you can use your XRDP software in order to remote into your Ubuntu machine. This post was really easy to write as the process to have KDE desktop working with XRDP is similar to the previous post we have published about installing LXQT desktop interface with XRDP.

Linux is offering a variety of desktop environment and we are not able to test all of them. So, if you are using another Desktop environment and if you have make it working and useable with XRDP remote session solution, you can always drop us a line, place a comment, provide a link,….

Sharing this information could be useful to other people out there.

That’s it (for this easy) post

Till next Time

See ya

6 thoughts on “Ubuntu 14.10 – KDE as alternative Desktop for XRDP sessions

  1. hello there,

    no you do no need the command about the LXDE
    Only use the restart comman

    I will update the picture to void any confusion

    till next time
    see ya

  2. What’s this non-sense when all I want to do is remote access to an Ubuntu system ??

    I mean : How hard can it be ? FFS.. Besides installing a defferent disto ?

  3. @Erik,

    you should upgrade to Ubuntu 16.04 or later.. Using these newer distribution it s possible to use unity desktop….You can find the info in this blog if you look in to xrdp section or simply use the search engine….. We are preparing our next posts about Unity and Ubuntu 17.04…

    Stay tuned
    Till next time

    See ya

  4. I’ve tried following the instructions but after I click on “Connect” in the Remote Desktop dialogue in Windows I am prompted by a log-in dialogue with fields “Module” (drop-down box containing different protocols such as VNC-any, SESMAN-any, When I try entering my login details using “sesman-xVnc” I see it trying to log in but I get “login failed”. It looks like this session manager isnt able to log me using my credentials. Am I missing a step ?

  5. @Robbie70,
    Login failed usually means that the password or user name is incorrect… in the username field in the xrdp login, can you type the password and ensure that the keyboard layout is set correctly.
    By default, the keybord layout would be set to English… could it be that the problem ?

    Till next time
    See ya

Leave a Reply