HOW TO CONFIGURE XRDP REMOTE DESKTOP SERVER IN RHEL/CENTOS 7
Introduction
In this article we are going to learn how to configure XRPD Remote Desktop Server in Linux Systems, Before that let me explain you what is XRDP. XRDP Remote Desktop Server is nothing but a service or a daemon which is allows user to take remote of Linux Operating System from RDP (Remote Desktop Protocol) clients. As we all know that RDP stands for Remote Desktop Protocol comes with Microsoft Windows operating Systems. With the help of XRDP we can able to take remote of Linux Operating Systems graphically from Windows Systems. XRDP is uses x11rdp at backend to manage X Sessions. XRDP is a open source application was invented on year 2005 which is nice replacement of rdesktop. There is also a nice alternative to XRDP is VNC but XRDP Remote Desktop Server is more reliable when we are talking about taking remote from MS Windows Systems. XRDP uses RSA Public Key and Private key encryption to transfer data over network so There is no risk of security as far as you are using this on Local Network but I would suggest you not to use over Internet. The main configuration file of XRDP is /etc/xrdp/xrdp.ini. For more Information and Documentation on XRDP go to Click Here!
So here I explained you a simple configuration steps to Configure XRDP Remote Desktop Server in RHEL/CentOS/Fedora.
Follow the Below Steps to Configure XRDP Remote Desktop Server :
Step : 1 Install Required Packages
Before we start the configuration of XRDP Remote Desktop Server we need to install all required packages and dependencies of XRDP.
Packages Required :
- epel-release.xxx.xx.xxx.rpm
- xrdp.xxx.xx.xxx.rpm
- tigervnc-server.xxx.xx.xxx.rpm
So Let’s go ahead and install our first package i.e. epel-release by using below command.
[root@localhost ~]# yum -y install epel-release # Install epel-release Package
Loaded plugins: fastestmirror, refresh-packagekit, security
Setting up Install Process
Loading mirror speeds from cached hostfile
* base: centos.mirror.net.in
* extras: mirror.tadu.vn
* updates: centos.mirror.net.in
Resolving Dependencies
--> Running transaction check
---> Package epel-release.noarch 0:6-8 will be installed
--> Finished Dependency Resolution
Dependencies Resolved
================================================================================
Package Arch Version Repository Size
================================================================================
Installing:
epel-release noarch 6-8 extras 14 k
Transaction Summary
================================================================================
Install 1 Package(s)
Total download size: 14 k
Installed size: 22 k
Downloading Packages:
epel-release-6-8.noarch.rpm | 14 kB 00:00
Running rpm_check_debug
Running Transaction Test
Transaction Test Succeeded
Running Transaction
Installing : epel-release-6-8.noarch 1/1
Verifying : epel-release-6-8.noarch 1/1
Installed:
epel-release.noarch 0:6-8
Complete!
Now install remaining packages i.e. xrdp, tigervnc-server by using below command.
[root@localhost ~]# yum -y install xrdp tigervnc-server # Install xrdp Package
Loaded plugins: fastestmirror, refresh-packagekit, security
Setting up Install Process
Loading mirror speeds from cached hostfile
* base: centos.mirror.net.in
* epel: ftp.jaist.ac.jp
* extras: mirror.tadu.vn
* updates: centos.mirror.net.in
Resolving Dependencies
--> Running transaction check
---> Package tigervnc-server.x86_64 0:1.1.0-18.el6 will be installed
--> Processing Dependency: xorg-x11-fonts-misc for package: tigervnc-server-1.1.0-18.el6.x86_64
---> Package xrdp.x86_64 0:0.6.1-4.el6 will be installed
--> Running transaction check
---> Package xorg-x11-fonts-misc.noarch 0:7.2-11.el6 will be installed
--> Finished Dependency Resolution
Dependencies Resolved
================================================================================
Package Arch Version Repository Size
================================================================================
Installing:
tigervnc-server x86_64 1.1.0-18.el6 base 1.0 M
xrdp x86_64 0.6.1-4.el6 epel 244 k
Installing for dependencies:
xorg-x11-fonts-misc noarch 7.2-11.el6 base 5.8 M
Transaction Summary
================================================================================
Install 3 Package(s)
Total download size: 7.1 M
Installed size: 11 M
Downloading Packages:
(1/3): tigervnc-server-1.1.0-18.el6.x86_64.rpm | 1.0 MB 00:01
(2/3): xorg-x11-fonts-misc-7.2-11.el6.noarch.rpm | 5.8 MB 00:10
(3/3): xrdp-0.6.1-4.el6.x86_64.rpm | 244 kB 00:01
--------------------------------------------------------------------------------
Total 514 kB/s | 7.1 MB 00:14
warning: rpmts_HdrFromFdno: Header V3 RSA/SHA256 Signature, key ID 0608b895: NOKEY
Retrieving key from file:///etc/pki/rpm-gpg/RPM-GPG-KEY-EPEL-6
Importing GPG key 0x0608B895:
Userid : EPEL (6) <epel@fedoraproject.org>
Package: epel-release-6-8.noarch (@extras)
From : /etc/pki/rpm-gpg/RPM-GPG-KEY-EPEL-6
Running rpm_check_debug
Running Transaction Test
Transaction Test Succeeded
Running Transaction
Installing : xorg-x11-fonts-misc-7.2-11.el6.noarch 1/3
Installing : tigervnc-server-1.1.0-18.el6.x86_64 2/3
Installing : xrdp-0.6.1-4.el6.x86_64 3/3
Verifying : xrdp-0.6.1-4.el6.x86_64 1/3
Verifying : tigervnc-server-1.1.0-18.el6.x86_64 2/3
Verifying : xorg-x11-fonts-misc-7.2-11.el6.noarch 3/3
Installed:
tigervnc-server.x86_64 0:1.1.0-18.el6 xrdp.x86_64 0:0.6.1-4.el6
Dependency Installed:
xorg-x11-fonts-misc.noarch 0:7.2-11.el6
Complete!
Also Read :
- STEP BY STEP TIGERVNC SERVER CONFIGURATION – A REMOTE DESKTOP APPLICATION FOR LINUX
- HOW TO CONFIGURE TELNET SERVER AND TELNET CLIENT IN RHEL/CENTOS/FEDORA
Step : 2 Configure Main configuration File of XRDP Remote Desktop Server (xrdp.ini)
We have installed all required packages, Now let’s have a look at configuration part. The main configuration file of xrdp Remote Desktop Server is xrdp.ini which is located at /etc/xrdp/xrdp.ini.
Here I am using default configuration of xrdp.ini file but you can modify or configure differently as per your scenario or need.
[root@localhost ~]# nano /etc/xrdp/xrdp.ini #grey=d6d3ce #dark_grey=808080 #blue=08246b #dark_blue=08246b #white=ffffff #red=ff0000 #green=00ff00 #background=626c72 [xrdp1] name=Local User Authentication # This name will show during Authentication lib=libvnc.so username=ask # "ask" means XRDP will ask for Username during Authentication password=ask # XRDP will ask for Password during Authentication ip=127.0.0.1 port=-1 # "-1" Looks for Free Port to Connect
Step : 3 Start xrdp Service
Start the xrdp service.
[root@localhost ~]# /etc/init.d/xrdp start # Start xrdp Service
Starting xrdp: [ OK ]
Starting xrdp-sesman: [ OK ]
Now start the xrdp service at startup.
[root@localhost ~]# chkconfig --level 35 xrdp on # Start xrdp Service on startup
[root@localhost ~]# chkconfig --list xrdp
xrdp 0:off 1:off 2:off 3:on 4:off 5:on 6:off
Step : 4 Stop Iptables Service
Stop the Linux Firewall Service i.e iptables.
[root@localhost ~]# /etc/init.d/iptables stop # Stop the Firewall
iptables: Setting chains to policy ACCEPT: filter [ OK ]
iptables: Flushing firewall rules: [ OK ]
iptables: Unloading modules: [ OK ]
Step : 5 Testing from Client Side
We have done with our configuration part from Server Side, Let’s check from client side to confirm if XRDP Remote Desktop Server is working properly or not.
For that just go and login any Microsoft Windows Operating System (eg : Windows XP, Windows 7, Windows 10) and open the Remote Desktop Connection Client by following below steps : START -> All Program -> Accessories -> Remote Desktop Connection OR Just go to Start->Run and type mstsc. then you will able to see a windows like as shown on the snapshot below.
Then enter the IP Address of XRDP Remote Desktop Server on Computer Text Box and click on connect as shown on the snapshot below.
Then click on Yes.
As we can see below we have connected to XRDP Server and now it’s asking for Username & Password, Here just enter the local Username and Password of Linux System.
For eg: I have a Username i.e. elinuxbook
[root@localhost ~]# cat /etc/passwd | grep -i elinuxbook elinuxbook:x:500:500:elinuxbook:/home/elinuxbook:/bin/bash
Follow the Snapshot below for your Reference.
We have successfully connected to XRDP Remote Desktop Server and able to take Remote of our Linux System. Refer the snapshot below.
This is how we can configure xrdp remote desktop server in RHEL / CentOS 7. On my next article I will explain you more deeply on XRDP Remote Desktop Server till then stay tuned to elinuxbook.com
If you found this article useful then Like Us, Share Us, Subscribe our Newsletter OR if you have something to say then feel free to comment on the comment box below.