This tutorial is for setting up an Ubuntu EC2 for RDP
In this tutorial, I will be using nano for this. To exit and save, do CTRL-X
followed by Y
and ENTER
-
Boot up EC2 - Ubuntu 14.04 (LTS)
-
Once the instance is all boot up, update it:
sudo apt-get update
sudo apt-get upgrade
-
sudo nano /etc/ssh/sshd_config
-
Change
PasswordAuthentication no
toPasswordAuthentication yes
-
Restart SSH:
sudo /etc/init.d/ssh restart
ORsudo /etc/init.d/sshd restart
-
Go into root:
sudo -i
-
Set password for ubuntu:
passwd ubuntu
-
Once you've finished setting your password, go back to ubuntu user:
su ubuntu & cd
-
Install Ubuntu desktop functionality:
export DEBIAN_FRONTEND=noninteractive
sudo -E apt-get update
sudo -E apt-get install -y ubuntu-desktop
-
Install XRDP and XFCE4:
sudo apt-get install xfce4 xrdp
sudo apt-get install xfce4 xfce4-goodies
-
Make XFCE4 the default for RDP connections:
echo xfce4-session > ~/.xsession
-
Copy .xsession to the /etc/skel folder so xfce4 is set as the default window manager for any new user accounts that are created.
sudo cp /home/ubuntu/.xsession /etc/skel
-
Allow host port to connect to xrdp.ini:
sudo nano /etc/xrdp/xrdp.ini
-
Change
port=-1
toport=ask-1
-
Restart
xrdp
:sudo service xrdp restart
-
Go back to AWS and make sure your security group includes
inbound access to RDP 3389
-
Go into Microsoft Remote Desktop, type in your IP address with:
XX.XX.XXX.XX:3389
Check this link - and this Untested but Solutions to 14.x to 15.x: ... to be continued
sudo do apt-get update
sudo apt-get dist-upgrade
sudo do-release-upgrade