Remote Desktop
Remote Desktop
Saturday, October 15, 2016
1:55 PM
Connect with Remote Desktop to a Lubuntu machine using xrdp. It uses vnc4server to spin up LXDE sessions on your Lubuntu machine.
Install xrdp |
sudo apt-get install xrdp |
If you try connecting to your machine, you’re going to get a grey desktop. xrdp is trying to use the command “startx” to start a window manager. On Lubuntu, this will not work. You need xrdp to use the command “lxsession”.
Create or edit ~/.xsession and make it look like this:
#!/bin/sh
/usr/bin/lxsession -s Lubuntu -e LXDE
Save, reboot your computer, and try connecting from your Remote Desktop client. Voilà!
From <https://wademurray.com/2014/xrdp-remote-desktop-on-lubuntu-14-04/>
…doesn't connect to the local login, creates a new one. Spent several hours trying to find a solution when the more profitable thing to do would be get to the colour map editing, which was the whole point of wanting a remote connection to begin with! (so I could use the desktop computer with dual monitors and better keyboard)
If you want the latest and greatest Guacamole (currently 0.9.8), use the instructions on the Guacamole website: http://guac-dev.org/doc/gug/installing-guacamole.html
If you are OK with a much older version, you can install the "server" using the normal sudo apt-get install
$ sudo
apt-get install guacamole
$ sudo apt-get install guacamole-tomcat
Then you have to edit/configure the user-mapping.xml file which is found in /etc/guacamole. A simple user-mapping.xml that I use for RDP connectivity is the following:
<user-mapping>
<!--
Per-user authentication and config information -->
<authorize
username="login-user-name"
password="login-passwd">
<connection
name="name-of-server">
<protocol>rdp</protocol>
<param
name="hostname">localhost</param>
<param
name="port">3389</param>
<param
name="color-depth">24</param>
<param
name="width">1280</param>
<param
name="height">720</param>
<param
name="enable-printing">true</param>
<param
name="enable-drive">true</param>
<param
name="drive-path">/home/login_name</param>
</connection>
</authorize>
</user-mapping>
Now... that install the Guacamole server onto your Ubuntu machine ... but if you want to see a desktop you will need to realize 1 limitation first and also understand what you need to do to finish this up.
The limitation: Neither Ubuntu's Unity desktop nor Gnome3 will work with any remote desktop sw I am aware of. So to have a usable desktop for "remote desktop" you should install either Mate, LXDE or XFCE.
Mate is pretty easy to use and there are lots of examples of how to install it onto whatever version of Ubuntu you are using.
For Ubuntu 14.04 here is a setup example: http://itsfoss.com/install-mate-desktop-ubuntu-14-04/
Next you would need to install a couple more items:
freerdp...
$ sudo apt-get install freerdp-x11
and you need x11rdp on the "server" side. The easiest way to get the very latest built/installed for you is to use a couple scripts from scarygliders:
http://scarygliders.net/2014/03/19/x11rdp-o-matic-version-3-10-released/
You will need GIT installed on your server:
$ sudo apt-get install git
then use GIT to pull/copy the scaryglider "build" environment for RDP and x11RDP.
$ git clone https://github.com/scarygliders/X11RDP-o-Matic.git
change directory into X11RDP-o-Matic directory that the above GIT command copied the build packages to...
$ cd X11RDP-o-Matic
next you need to start the scarygliders "build" process.
$ sudo ./X11rdp-o-matic.sh --justdoit
NOTE: this takes QUITE A WHILE to complete. On my 8 core 32GB system it can take 20 minutes.
After the build is complete you have 1 more step and that is to configure the "type" of session (rdp or vnc) you want the server to use so execute the following:
$ sudo ./RDPsesconfig.sh
I know this sounds complicated or a lot of work but its not really and scarygliders script is terrific in that it takes a very complicated build process and reduces it to 1 command for you. What you get is assurance that you are using the latest RDP and X11RDP on the server.
If all of this is done then you might want to reboot your server before trying to connect remotely with a browser by pointing the browser to the IP of the server/guacamole
so example: 192.168.1.66:8080/guacamole
Remember Tomcat uses port 8080 by default, so your firewall(s) have to permit that.
I've used Guacamole to remotely log into cloud servers and virtual machines (KVM, Virtualbox etc). Its not perfect but it works pretty well.
From <http://askubuntu.com/questions/693479/guacamole-html5-rdp-gateway-trouble/>
Created with OneNote.