The script hereafter is outdated and has been replaced by a newer version. Please Check the Download page for latest version. |
Hello World,
If you have followed up during this month, you have probably noticed that have been focusing again a little bit more than necessary on xRDP and Ubuntu Operating system. With the release of Ubuntu 19.04, we have spend some time in trying to improve the xRDP installation process. We have started from a manual installation and we have tried to tackle all the annoyances encountered when working with xRDP. The following posts provide our installation process and our findings…
- xRDP – Manual Installation on Ubuntu 19.04
- xRDP – Fixing Look n’ Feel Settings in Ubuntu 19.04 Remote Session
- xRDP – New “Authentication Required…” Popup showing up in Ubuntu 19.04
- xRDP – Missing packages for Sound Redirection in Ubuntu 19.04
Based on these posts, and their findings, it’s was clear that an updated version of the script would be welcome. The small changes introduced in Ubuntu 19.04 have slightly affected the way xRDP needs to be installed and tweaked in order to provide the best user experience.
In this post, we will present the new version of the script that integrate all the things and actions that can be done to provide a smooth installation experience while performing the installation from the sources (i.e. compiling the xrdp and xorgxrdp packages)
So, let’s see what’s the new version of the script looks like
Note : Please always check this page, to get the latest version of the script
Custom Install Script – Version 3.0
The previous script version was set to 2.4. Adding Ubuntu 19.04 support only into the script would have lead us to increment the version of the script to 2.5. However, because we have modified the code and integrated new ways of performing some post configuration actions, we had the feeling that setting the script version to 3.0 would make more sense. The script includes the following changes
- Added support for Ubuntu 19.04
- to use Ubuntu desktop interface in the remote session, we have updated the code and we are using the .xsessionrc capabilities
- sound redirection option is still available. However, because xrdp-pulseaudio-installer package is not available in Ubuntu 19.04, we are compiling from sources
- -g parameter has been removed as the xsessionrc approach fixes the GDM login look and feel
- integrate the patch for Ubuntu 18.04.2 by compiling against the correct version of xserver-xorg-core packages
Prerequisites and assumptions
We assume that you have internet connection available and that you are indeed running one of the following version of Ubuntu
- Ubuntu 18.04 (up to Ubuntu 18.04.2)
- Ubuntu 18.10
- Ubuntu 19.04
- We have performed the test on a Virtual Machine running on Virtual box (on Windows 2012 R2) with Sound enabled !!!
- No additional Desktop interface will be used. The remote desktop session will display the Ubuntu tweak Gnome Desktop interface
The Script version 3.0
Important Note :
If you copy/paste the script, you might encounter some issues because font formatting might be not maintained during the copy/paste operation. Please ensure that format is accurate before launching the script. A downloadable version of the script is available at the bottom of the post
Disclaimer : As usual, use this at your own risk !!
#!/bin/bash ##################################################################################################### # Script_Name : install-xrdp-3.0.sh # Description : Perform a custom installation of xrdp # on ubuntu 18.04 and later # Date : May 2019 # written by : Griffon # Web Site :http://www.c-nergy.be - http://www.c-nergy.be/blog # Version : 3.0 # History : 3.0 - Added support for Ubuntu 19.04 # - New code for Look'n feel using xsessionrc method # - New code for enabling Sound Redirection - compiling from source # - Removed -g parameter # : 2.4 - Proper fix for U18.04.2 when xserver-xorg-core-hwe-18.04 # changed code to detect whicht package in use and perform most appropriate compilation # : 2.3 - Quick Fix Ubuntu 18.04.2 issue when xserver-xorg-core-hwe-18.04 installed # : 2.2 - Add Support for Ubuntu 18.10 and Yaru Theme # : 2.1 - Add logic to enable sound redirection for U18.04 # - re-write code logic to include functions # - Removed support for Ubuntu 17.10 as reached end of support # : 2.0 - Initial Version for Ubuntu system with Gnome Desktop # : 1.x - Script for Ubuntu 16.04 or later # Disclaimer : Script provided AS IS. Use it at your own risk.... #################################################################################################### #---------------------------------------------------# # Detecting if Parameters passed to script .... #---------------------------------------------------# while getopts s: option do case "${option}" in s) fixSound=${OPTARG};; esac done #---------------------------------------------------# # Script Version information Displayed # #---------------------------------------------------# echo /bin/echo -e "\e[1;36m !-------------------------------------------------------------!\e[0m" /bin/echo -e "\e[1;36m ! Custom XRDP Installation Script - Ver 3.0 !\e[0m" /bin/echo -e "\e[1;36m ! Written by Griffon - May 2019 - www.c-nergy.be !\e[0m" /bin/echo -e "\e[1;36m !-------------------------------------------------------------!\e[0m" echo #--------------------------------------------------------------------------# # -----------------------Function Section - DO NOT MODIFY -----------------# #--------------------------------------------------------------------------# #---------------------------------------------------# # Function 1 - Install Prereqs... #---------------------------------------------------# install_prereqs() { echo /bin/echo -e "\e[1;33m !---------------------------------------------!\e[0m" /bin/echo -e "\e[1;33m ! Installing PreReqs packages..Proceeding. ! \e[0m" /bin/echo -e "\e[1;33m !---------------------------------------------!\e[0m" echo /bin/echo -e "\e[1;33m |-| Detecting xserver-xorg-core package installed \e[0m" xorgver=$(dpkg-query -W -f ='${Status}\n' xserver-xorg-core | awk {'print $3'}) if [[ "$xorgver" = *not-installed* ]]; then # - hwe 18.04 is installed /bin/echo -e "\e[1;32m |-| xorg package version: xserver-xorg-core-hwe-18.04 \e[0m" echo sudo apt-get -y install libx11-dev libxfixes-dev libssl-dev libpam0g-dev libtool libjpeg-dev flex bison gettext autoconf libxml-parser-perl libfuse-dev xsltproc libxrandr-dev python-libxml2 nasm xserver-xorg-dev-hwe-18.04 fuse pkg-config git intltool xserver-xorg-core-hwe-18.04 else # - hwe 18.04 not installed /bin/echo -e "\e[1;32m |-| xorg package version: xserver-xorg-core \e[0m" echo sudo apt-get -y install libx11-dev libxfixes-dev libssl-dev libpam0g-dev libtool libjpeg-dev flex bison gettext autoconf libxml-parser-perl libfuse-dev xsltproc libxrandr-dev python-libxml2 nasm xserver-xorg-dev fuse pkg-config git intltool xserver-xorg-core fi } #---------------------------------------------------# # Function 2 - Download XRDP Binaries... #---------------------------------------------------# get_binaries() { echo /bin/echo -e "\e[1;33m !---------------------------------------------!\e[0m" /bin/echo -e "\e[1;33m ! Download xRDP Binaries.......Proceeding. ! \e[0m" /bin/echo -e "\e[1;33m !---------------------------------------------!\e[0m" echo cd ~/Downloads ## -- Download the xrdp latest files echo /bin/echo -e "\e[1;32m !---------------------------------------------!\e[0m" /bin/echo -e "\e[1;32m ! Preparing download xrdp package !\e[0m" /bin/echo -e "\e[1;32m !---------------------------------------------!\e[0m" echo git clone https://github.com/neutrinolabs/xrdp.git echo /bin/echo -e "\e[1;32m !---------------------------------------------!\e[0m" /bin/echo -e "\e[1;32m ! Preparing download xorgxrdp package !\e[0m" /bin/echo -e "\e[1;32m !---------------------------------------------!\e[0m" echo git clone https://github.com/neutrinolabs/xorgxrdp.git } #---------------------------------------------------# # Function 3 - compiling xrdp... #---------------------------------------------------# compile_source() { # -- Compiling xrdp package first echo /bin/echo -e "\e[1;33m !---------------------------------------------!\e[0m" /bin/echo -e "\e[1;33m ! Compile xRDP packages .......Proceeding. ! \e[0m" /bin/echo -e "\e[1;33m !---------------------------------------------!\e[0m" echo cd ~/Downloads/xrdp sudo ./bootstrap sudo ./configure --enable-fuse --enable-jpeg sudo make #-- check if no error during compilation if [ $? -eq 0 ] then /bin/echo -e "\e[1;33m |-| Make Operation Completed successfully \e[0m" else echo echo /bin/echo -e "\e[1;31m !---------------------------------------------!\e[0m" /bin/echo -e "\e[1;31m ! Error while Executing make !\e[0m" /bin/echo -e "\e[1;31m ! The Script is exiting.... !\e[0m" /bin/echo -e "\e[1;31m !---------------------------------------------!\e[0m" exit fi sudo make install echo /bin/echo -e "\e[1;33m !---------------------------------------------!\e[0m" /bin/echo -e "\e[1;33m ! Compile xorgxrdp packages....Proceeding. ! \e[0m" /bin/echo -e "\e[1;33m !---------------------------------------------!\e[0m" echo cd ~/Downloads/xorgxrdp sudo ./bootstrap sudo ./configure sudo make # check if no error during compilation if [ $? -eq 0 ] then echo /bin/echo -e "\e[1;33m |-| Make Operation Completed successfully \e[0m" echo else echo /bin/echo -e "\e[1;31m !---------------------------------------------!\e[0m" /bin/echo -e "\e[1;31m ! Error while Executing make !\e[0m" /bin/echo -e "\e[1;31m ! The Script is exiting.... !\e[0m" /bin/echo -e "\e[1;31m !---------------------------------------------!\e[0m" exit fi sudo make install } #---------------------------------------------------# # Function 5 - create services .... #---------------------------------------------------# enable_service() { echo /bin/echo -e "\e[1;33m !---------------------------------------------!\e[0m" /bin/echo -e "\e[1;33m ! Creating xRDP services.......Proceeding. ! \e[0m" /bin/echo -e "\e[1;33m !---------------------------------------------!\e[0m" echo sudo systemctl daemon-reload sudo systemctl enable xrdp.service sudo systemctl enable xrdp-sesman.service sudo systemctl start xrdp } #---------------------------------------------------# # Function 6 - Install Gnome Tweak Tool.... #---------------------------------------------------# install_tweak() { echo /bin/echo -e "\e[1;33m !---------------------------------------------!\e[0m" /bin/echo -e "\e[1;33m ! Installing Gnome Tweak...Proceeding... ! \e[0m" /bin/echo -e "\e[1;33m !---------------------------------------------!\e[0m" echo sudo apt-get install gnome-tweak-tool -y } #--------------------------------------------------------------------# # Fucntion 7 - Allow console Access .... #--------------------------------------------------------------------# allow_console() { echo /bin/echo -e "\e[1;33m !---------------------------------------------!\e[0m" /bin/echo -e "\e[1;33m ! Granting Console Access...Proceeding... ! \e[0m" /bin/echo -e "\e[1;33m !---------------------------------------------!\e[0m" echo sudo sed -i 's/allowed_users=console/allowed_users=anybody/' /etc/X11/Xwrapper.config } #---------------------------------------------------# # Function 8 - create policies exceptions .... #---------------------------------------------------# create_polkit() { echo /bin/echo -e "\e[1;33m !---------------------------------------------!\e[0m" /bin/echo -e "\e[1;33m ! Creating Polkit File...Proceeding... ! \e[0m" /bin/echo -e "\e[1;33m !---------------------------------------------!\e[0m" echo sudo bash -c "cat >/etc/polkit-1/localauthority/50-local.d/45-allow.colord.pkla" <<EOF [Allow Colord all Users] Identity=unix-user:* Action=org.freedesktop.color-manager.create-device;org.freedesktop.color-manager.create-profile;org.freedesktop.color-manager.delete-device;org.freedesktop.color-manager.delete-profile;org.freedesktop.color-manager.modify-device;org.freedesktop.color-manager.modify-profile ResultAny=no ResultInactive=no ResultActive=yes [Allow Package Management all Users] Identity=unix-user:* Action=org.debian.apt.*;io.snapcraft.*;org.freedesktop.packagekit.*;com.ubuntu.update-notifier.* ResultAny=no ResultInactive=no ResultActive=yes EOF } #---------------------------------------------------# # Function 9 - Fixing Theme and Extensions .... #---------------------------------------------------# fix_theme() { echo /bin/echo -e "\e[1;33m !---------------------------------------------!\e[0m" /bin/echo -e "\e[1;33m ! Fix Theme and extensions...Proceeding... !\e[0m" /bin/echo -e "\e[1;33m !---------------------------------------------!\e[0m" echo sudo sed -i.bak "4 a #Improved Look n Feel Method\ncat <<EOF > ~/.xsessionrc\nexport GNOME_SHELL_SESSION_MODE=ubuntu\nexport XDG_CURRENT_DESKTOP=ubuntu:GNOME\nexport XDG_CONFIG_DIRS=/etc/xdg/xdg-ubuntu:/etc/xdg\nEOF\n" /etc/xrdp/startwm.sh echo } #---------------------------------------------------# # Function 10 - Enable Sound Redirection .... #---------------------------------------------------# enable_sound() { echo /bin/echo -e "\e[1;33m !---------------------------------------------!\e[0m" /bin/echo -e "\e[1;33m ! Enabling Sound Redirection... !\e[0m" /bin/echo -e "\e[1;33m !---------------------------------------------!\e[0m" echo # Step 1 - Enable Source Code Repository sudo apt-add-repository -s 'deb http://be.archive.ubuntu.com/ubuntu/ '$codename' main restricted' sudo apt-add-repository -s 'deb http://be.archive.ubuntu.com/ubuntu/ '$codename' restricted universe main multiverse' sudo apt-add-repository -s 'deb http://be.archive.ubuntu.com/ubuntu/ '$codename'-updates restricted universe main multiverse' sudo apt-add-repository -s 'deb http://be.archive.ubuntu.com/ubuntu/ '$codename'-backports main restricted universe multiverse' sudo apt-add-repository -s 'deb http://be.archive.ubuntu.com/ubuntu/ '$codename'-security main restricted universe main multiverse' sudo apt-get update # Step 2 - Install Some PreReqs sudo apt-get install git libpulse-dev autoconf m4 intltool build-essential dpkg-dev -y sudo apt build-dep pulseaudio -y # Step 3 - Download pulseaudio source in /tmp directory - Do not forget to enable source repositories cd /tmp sudo apt source pulseaudio # Step 4 - Compile pulsever=$(pulseaudio --version | awk '{print $2}') cd /tmp/pulseaudio-$pulsever sudo ./configure # step 5 - Create xrdp sound modules sudo git clone https://github.com/neutrinolabs/pulseaudio-module-xrdp.git cd pulseaudio-module-xrdp sudo ./bootstrap sudo ./configure PULSE_DIR="/tmp/pulseaudio-$pulsever" sudo make #Step 6 copy files to correct location (as defined in /etc/xrdp/pulse/default.pa) cd /tmp/pulseaudio-$pulsever/pulseaudio-module-xrdp/src/.libs sudo install -t "/var/lib/xrdp-pulseaudio-installer" -D -m 644 *.so sudo install -t "/usr/lib/pulse-$pulsever/modules" -D -m 644 *.so echo } fix_ssl() { echo /bin/echo -e "\e[1;33m !---------------------------------------------!\e[0m" /bin/echo -e "\e[1;33m ! Fixing SSL Cert Issue ... !\e[0m" /bin/echo -e "\e[1;33m !---------------------------------------------!\e[0m" echo sudo adduser xrdp ssl-cert } #--------------------------------------------------------------------------# # -----------------------END Function Section -----------------# #--------------------------------------------------------------------------# #--------------------------------------------------------------------------# #------------ MAIN SCRIPT SECTION -------------------# #--------------------------------------------------------------------------# #---------------------------------------------------# # Step 0 - Try to Detect Ubuntu Version.... #---------------------------------------------------# version=$(lsb_release -sd) codename=$(lsb_release -sc) echo /bin/echo -e "\e[1;33m |-| Detecting Ubuntu version \e[0m" if [[ "$version" = *"Ubuntu 18.04"* ]]; then /bin/echo -e "\e[1;32m |-| Ubuntu Version : $version\e[0m" echo elif [[ "$version" = *"Ubuntu 18.10"* ]]; then /bin/echo -e "\e[1;32m |-| Ubuntu Version : $version\e[0m" echo elif [[ "$version" = *"Ubuntu 19.04"* ]]; then /bin/echo -e "\e[1;32m |-| Ubuntu Version : $version\e[0m" echo else /bin/echo -e "\e[1;31m !------------------------------------------------------------!\e[0m" /bin/echo -e "\e[1;31m ! Your system is not running Ubuntu 18.04 Edition and later !\e[0m" /bin/echo -e "\e[1;31m ! The script has been tested only on Ubuntu 18.04 and later !\e[0m" /bin/echo -e "\e[1;31m ! The script is exiting... !\e[0m" /bin/echo -e "\e[1;31m !------------------------------------------------------------!\e[0m" echo exit fi /bin/echo -e "\e[1;33m |-| Detecting Parameters \e[0m" #Detect if argument passed if [ "$fixSound" = "yes" ]; then /bin/echo -e "\e[1;32m |-| Sound Redirection Option...: [YES]\e[0m" else /bin/echo -e "\e[1;32m |-| Sound Redirection Option...: [NO]\e[0m" fi #---------------------------------------------------------# # Step 1 - Executing the installation & config tasks .... # #---------------------------------------------------------# echo /bin/echo -e "\e[1;36m !-------------------------------------------------------------!\e[0m" /bin/echo -e "\e[1;36m ! Installation Process starting.... !\e[0m" /bin/echo -e "\e[1;36m !-------------------------------------------------------------!\e[0m" echo /bin/echo -e "\e[1;33m |-| Proceed with installation..... \e[0m" echo install_prereqs get_binaries compile_source enable_service install_tweak allow_console create_polkit fix_theme fix_ssl if [ "$fixSound" = "yes" ]; then enable_sound fi #---------------------------------------------------# # Step 2 - Credits .... #---------------------------------------------------# echo /bin/echo -e "\e[1;36m !-----------------------------------------------------------------------!\e[0m" /bin/echo -e "\e[1;36m ! Installation Completed !\e[0m" /bin/echo -e "\e[1;36m ! Please test your xRDP configuration.A Reboot Might be required... !\e[0m" /bin/echo -e "\e[1;36m ! Written by Griffon - April 2019 - 3.0 - Install-xrdp-3.0.sh !\e[0m" /bin/echo -e "\e[1;36m !-----------------------------------------------------------------------!\e[0m" echo
How to Use the Script
The script usage has not changed since the previous version. So, instead of repeating the same information, we will summarize the necessary actions and options that are available with this version of the script.
Step 1 – Set Execute Right on the script
Download the install-xrdp-3.0.sh script to your system. You need to mark the script as executable . To do this, perform the following action in a terminal console
chmod +x ~/Downloads/install-xrdp-3.0.sh
Note : Adjust the path where the install-xrdp-3.0.sh script to reflect your environment
Step 2 – How to execute the script ?
Like the previous version of the script, you can decide to execute the script with no parameters to perform a “standard installation”. This installation mode will not compile the xrdp sound modules need to support sound redirection.
Before running it, ensure that internet connection is available (so you can download the necessary packages needed for the installation)
Standard way
To perform a standard installation, you execute the script with no parameters. Open a Terminal console, browse to the location where the script has been downloaded and issue the following command
./install-xrdp-3.0.sh
When the xrdp installation package will start, you be requested to enter your password. Provide the password and proceed with the installation. Wait for completion of the script. The machine will not reboot automatically when done so you can review the actions performed by the script….
When the script has finished, we recommend to reboot the system. After the reboot, a user should be able to perform a remote connection to the Ubuntu machine and will be presented with the Ubuntu Gnome Desktop interface with the Dock bar and the appropriate Yaru theme enabled. This installation will not configure sound redirection feature. However, if at a later stage, you want to implement the Sound redirection option, you could re-run the script and pass the parameters to enable the options selected. The script will re-run and pass the new parameters and your system should be working with the additional features enabled.
Enabling Sound redirection
To enable sound redirection features within your remote desktop session, it’s possible to pass the -s parameter to the script. In other words, in order to enable sound redirection at installation time, you will need to execute the following syntax
./install-xrdp-3.0.sh -s yes
When script execution is completed, the machine will not reboot so you can review the installation and detect possible elements that’s preventing the script execution. At completion, it’s recommended to reboot the machine so the changes made to the system can be applied accordingly.
Step 3 – Test your configuration
After a good reboot, you should be able to test your configuration. Using your favourite remote desktop client, perform a connection. You will be presented with the green login page from xRDP. Provide your credentials and if everything is working as expected, you should see your Ubuntu Desktop interface loading and you are ready to go and perform your work on the remote machine.
As a reminder, the same user can be connected either on the local machine or on the remote machine, not both at the same time. If a user is locally connected, and the same user tries to perform a remote desktop connection, the process will fail…If you disconnect from your remote session, you can reconnect to the same session and proceed with your work….
Download the Script
Please download the script : install-xrdp-3.0.sh
Final Notes
This is it for this post !
Out of the box, it’s possible to install the xrdp package and obtain the basic functionality (i.e. perform a remote desktop connection to an Ubuntu computer). However, look’n feel and the user experience with the default installation is not optimal. This is why we came up with the scripted installation approach. The scripted installation basically perform the additional configuration steps that would improve the user experience and increase user acceptance. So far, we have maintained 2 scripts.
- The Std-install-xrdp-xx.sh script is using the xRDP packages found in Ubuntu repositories to perform the installation and then post configuration actions are executed as well
- The Install-xrdp-xx.sh script is compiling from sources xRDP packages and then perform post configuration actions.
The Std install script and the custom install script have been updated and the code has been reviewed in order to include all the new ways of configuring an Ubuntu machine in order to use xRDP and have the best user experience. We are already looking forward and preparing new version of the script (Ubuntu 18.10 end of support – Ubuntu 19.10 coming, Ubuntu 20.04 LTS…). We still have some ideas and topics we haven’t talked about it which could be integrated into the next version of the script….
Next version of the script(s) might be full of surprise….:-)
Stay tuned
That’s is for today
Till next time
Hello Griffon,
Thanks for the great script !!
Version 3.0 is no longer available for download.
I changed the path to 3.1 and was able to download the next version.
But…
The script stops shortly before the end.
./bootrap
./configure
make
Does not work because it executes the commands at wrong folder
Maybe this will help you!
Thank you for all your work!
Chris
@Chris,
Thank you for notifying us :-). We have updated the link and now the download link should be pointing to the correct version
About the error ! can you provide us a screenshot or tell us at which level the script is failing (when compiling xrdp or xorgxrdp) ? Do you have have internet connection on the machine and which folder is missing… would it be the xrdp folder because the source was not downloaded
Thank again for letting us know and if you can provide us with the requested info, this would be great so we can fix any issues with this script
Till next time
See ya
Hello Griffon,
It would be my pleasure to help you.
Thanks for your quick reply.
What did not work.
The VM (Ubuntu 18.10 incl. All updates) has Internet access.
Step by step
chmod + x /Install-xrdp-3.0.sh
sudo ./install-xrdp-3.0.sh
After a short time this message appears:
./Install-xrdp-3.0.sh: Zeile 126: cd: /root/Downloads/xrdp: Datei oder Verzeichnis nicht gefunden
sudo: ./bootstrap: Befehl nicht gefunden
sudo: ./configure: Befehl nicht gefunden
make: *** Es wurden keine Ziele angegeben und keine „make“-Steuerdatei gefunden. Schluss.
!———————————————!
! Error while Executing make !
! The Script is exiting…. !
!———————————————!
He is looking for a directory called “bootstrap” but this is not in the folder of the installation script, the directory is under the automatically create subfolder xrdp.
./xrdp/.bootstrap
Which logs do you need?
Does the script create a log file?
Greetings!
Line 126:
cd ~/Downloads/xrdp
sudo ./bootstrap
sudo ./configure –enable-fuse –enable-jpeg
sudo make
I think so:
He indicates that the data is expected under “Downloads”.
My script is in the home directory – not under “Downloads”
So the mistake lies in the fact that the script must be in the download folder in order for the installation to work properly?
After moving it into Download:
root@srv1:/home/c-0309# sudo ./Install-xrdp-3.0.sh
!————————————————————-!
! Custom XRDP Installation Script – Ver 3.0 !
! Written by Griffon – May 2019 – http://www.c-nergy.be !
!————————————————————-!
|-| Detecting Ubuntu version
|-| Ubuntu Version : Ubuntu 18.10
|-| Detecting Parameters
|-| Sound Redirection Option…: [NO]
!————————————————————-!
! Installation Process starting…. !
!————————————————————-!
|-| Proceed with installation…..
!———————————————!
! Installing PreReqs packages..Proceeding. !
!———————————————!
|-| Detecting xserver-xorg-core package installed
|-| xorg package version: xserver-xorg-core
Paketlisten werden gelesen… Fertig
Abhängigkeitsbaum wird aufgebaut.
Statusinformationen werden eingelesen…. Fertig
autoconf ist schon die neueste Version (2.69-11).
bison ist schon die neueste Version (2:3.0.4.dfsg-1ubuntu1).
flex ist schon die neueste Version (2.6.4-6.2).
fuse ist schon die neueste Version (2.9.8-1ubuntu1).
libfuse-dev ist schon die neueste Version (2.9.8-1ubuntu1).
libjpeg-dev ist schon die neueste Version (8c-2ubuntu8).
libtool ist schon die neueste Version (2.4.6-4).
libx11-dev ist schon die neueste Version (2:1.6.7-1).
libxfixes-dev ist schon die neueste Version (1:5.0.3-1).
libxml-parser-perl ist schon die neueste Version (2.44-2build3).
libxrandr-dev ist schon die neueste Version (2:1.5.1-1).
pkg-config ist schon die neueste Version (0.29.1-0ubuntu2).
python-libxml2 ist schon die neueste Version (2.9.4+dfsg1-7ubuntu1).
intltool ist schon die neueste Version (0.51.0-5ubuntu1).
nasm ist schon die neueste Version (2.13.03-2).
gettext ist schon die neueste Version (0.19.8.1-8ubuntu0.1).
git ist schon die neueste Version (1:2.19.1-1ubuntu1.1).
libpam0g-dev ist schon die neueste Version (1.1.8-3.6ubuntu3).
libssl-dev ist schon die neueste Version (1.1.1-1ubuntu2.2).
xserver-xorg-core ist schon die neueste Version (2:1.20.1-3ubuntu2.1).
xserver-xorg-dev ist schon die neueste Version (2:1.20.1-3ubuntu2.1).
xsltproc ist schon die neueste Version (1.1.32-2ubuntu0.1).
0 aktualisiert, 0 neu installiert, 0 zu entfernen und 0 nicht aktualisiert.
!———————————————!
! Download xRDP Binaries…….Proceeding. !
!———————————————!
./Install-xrdp-3.0.sh: Zeile 94: cd: /root/Downloads: Datei oder Verzeichnis nic ht gefunden
!———————————————!
! Preparing download xrdp package !
!———————————————!
fatal: Zielpfad ‘xrdp’ existiert bereits und ist kein leeres Verzeichnis.
!———————————————!
! Preparing download xorgxrdp package !
!———————————————!
fatal: Zielpfad ‘xorgxrdp’ existiert bereits und ist kein leeres Verzeichnis.
!———————————————!
! Compile xRDP packages …….Proceeding. !
!———————————————!
./Install-xrdp-3.0.sh: Zeile 126: cd: /root/Downloads/xrdp: Datei oder Verzeichn is nicht gefunden
sudo: ./bootstrap: Befehl nicht gefunden
sudo: ./configure: Befehl nicht gefunden
make: *** Es wurden keine Ziele angegeben und keine „make“-Steuerdatei gefunden. Schluss.
!———————————————!
! Error while Executing make !
! The Script is exiting…. !
!———————————————!
root@srv1:/home/c-0309# ^C
root@srv1:/home/c-0309# cd Down
bash: cd: Down: Datei oder Verzeichnis nicht gefunden
The script switches between the users root and c-0309.
That seems to be the problem!
I do not run the script as c-0309 but as root.
Would it be better to work with the user c-0309 and then with the command “sudo”?
@Chris,
Sorry for the delay… indeed, the script is designed to run as a standard user and no root account (this is security best practice).. Thank to your feedback, we might update the script again and try to catch this situation
Thanks for the feedback and till next time
See ya
Hello,
great script!
But how can I start the xrdp listener to ipv6, too?
Like it written in xrdp.ini: port=3389 should link to all ip adresses.
It seams that xrdp does not recognize the ipv6 address.
(Refer netstat -naptu)
Can someone help me?
Hopefully it is just a small property.
@Frank,
Never tried that…. I’m not sure that xrdp support IPV6… we will need to check and perform some tests…
Thanks for the visit and the interesting question….:-)
keep in touch
till next time
See ya
Hi,
Is it possible to use the xRDP login screen to auto fill GDM login page or Lightdm ? It’s annoying to have to type the same ID twice.
Thx 🙂
@Alexandre,
In the past, it was possible to specify username and password to be used when using xrdp software…. you have to look for settings username and password in /etc/xrdp/xrdp.ini file and check if this is still working…. We could provide a step by step guide but we are really busy till end of this week…so maybe next week or week after….. (no guarantee)
Try already with these settings and let us know if this is working for you
Thanks for the visit and for challenging us…
Till next time
See ya
When I log in from Windows 10 remote desktop, I am immediately logged out and window closes. Any ideas?
@Bmandl,
This usually occurs when you are locally logged on your ubuntu machine and you are trying to perform a remote desktop connection (i.e. using the same account). To avoid this issue, you have to logoff from your UBuntu Machine completely and then you can perform a remote session to your ubuntu or you have to use a different user account that the one logged on the Ubuntu machine and perform a remote session
Hope this help
Till next time
See ya
Greetings Griffon,
Firstly, thank you so much for the custom script. I was able to get xRDP working in the past but was unable to get it working with Gnome until I found your page. Your efforts are much appreciated!
I am running into the problem with loss of keyboard and mouse at the local terminal. I have reviewed the information located at https://c-nergy.be/blog/?p=13390 and found all packages mentioned to already be present on my system (probably because I installed xRDP using your custom script). I have searched and most of the hits I find are related to the xserver-xorg-core package which leaves me with an option to reboot (not desirable) to restore the local console.
I am hoping I missed something along the way that can help to prevent this from occurring.
Regards,
A huge thanks to making all the steps that you usually have to find independently (and hope for the right order), a simple install script.
@Cori,
Thanks for passing by, using the script and providing feedback on it… always happy to see that our work is useful to others…
Till next time
See ya
@AdamB,
ok, this is a strange one then. Indeed, if you have used the custom script, xrdp compiles against the correct xserver-xorg-core package and the keyboard/mouse issue should not even be there….
We have run the script again in our lab and we are not encountering the issue….
We will need to investigate a little bit more….
Till next time
see ya
Hi,
thanks for the script, it worked like a charm. As I usually move the scripts in ~/bin, that I create for my own scripts, I only had to replace the occurences of ~/Downloads to ~/bin in the script. Since my VMs are in french, I was not sure if it would create a “Downloads” folder or place the files in “Téléchargements”.
I do have several linux VMs on my XenServer but was unable to enable xRDP on my Ubuntu Mate 18.04 with my usual procedure.
Thanks again.
Thanks so much for this script. I was having trouble getting XRDP to work on my new install of ubuntu 18.04.3 until I ran this. Solves so many problems!
However now I have one slight problem: Gnome apps are now unable to ask for my authentication as an admin when I am logged on via XRDP (apps such as software center and updater and settings). When I log on on the machine itself, they ask me for my admin password as expected, but when I am logged in via XRDP they just tell me I don’t have permission.
Not realising this issue, I also ran this script on another machine of mine. (This machine runs Ubuntu 18.04.01 and it already had XRDP installed – I installed it with your standard install script v0.2 some time ago – and it previously had no problems with gnome apps asking for authentication.) Now, having run this script, I have this problem on that machine too – gnome apps are now just tell me I don’t have permission rather than asking for authentication.
Do you know what might be causing this and if there is a workaround?
Thanks in advance.
@DanielA,
Thanks for the visit and for sharing your experience with us… we are always happy to see that our work can be useful
Till next time
See ya
@Kieronam,
This seems to be a random but known issue with xRDP and the software center… We would guess that the issue is probably related to the Polkit technology that’s blocking the installation when connected through remote connection..
We never had time to investigate further (this would be probably one of the topic in the future). In the meantime, the workaround is to perform installation through command line when remote connected..
We know this is not ideal but at least you should be able to proceed
Hope this help
till next time
See ya
Hi Griffon,
I installed xRDP using your script 3.0 on Ubuntu 18.04.4. when I tried to access my machine from Windows 10 using Remote Desktop Connection application after passing the credentials a black screen is displayed for a second then it closed the window. I tried it again and again but after the black screen, the window closed.
I don’t know what happened and what I have to do.
@Shafqat,
First, please note that there is a newer version of the script (please always check the page http://www.c-nergy.be/products.html
Based on your description and symptoms, it seems that you are trying to login on your remote desktop using a user account that’s already logged on (locally) on the machine.
As a reminder, please note that a single user account (ex.John.Doe) can be logged either locally on Ubuntu or Remotely through xRDP but not both at the same time…
You didn’t specify which mode you have been using (standard or Custom installation mode). IF you have used custom mode, we need to know which version of xRDP you are using (0.12 or 0.13….)
Check also the logs to see if there are any hints that could be helpful to solve this issue
Hope this help
Till next time
See ya
I cannot download 3.1 version, an you update link?
thanks!
@Mike,
Thank you for visiting our blog and providing some feedback. So, first, please note that the script (as mentioned in the beginning of the post) is deprecated. You have to use a more recent version. We recommend you to always check for the latest version at https://www.c-nergy.be/products.html. the latest version of the script is 1.5. for the xrdp-installer script which combine the standard and custom script into a single script
In the page https://www.c-nergy.be/products.html, you have also a link that redirect you to the archive repository…There you can find all the versions of the script that has been published
Hope this help
Till next time
See ya