Monday, May 16, 2016

[Quick Install: RDP]: HOW TO INSTALL AND CONFIGURE XRDP FOR REMOTE SESSION

HOW TO INSTALL AND CONFIGURE XRDP FOR REMOTE SESSION


In this tutorial we will learn about xrdp. We will discuss difference between xrdp and VNC briefly. We will install and xrdp server.
Introduction
Xrdp is daemon that supports Windows Remote Desktop Protocol. Xrdp is very easy to config and use as compare to VNC server. Xrdp utility provide us platform to access Linux in Windows environment. Xrdp is light weight and easy to setup as compared to VNC. With xrdp you can lock remote system and can map local devices where as in VNC you can not.. By default it listens on port number 3389.
Make sure you have installed GNOME Desktop on your distro.
To  install xrdp and tigervnc-server you can use command.
[root@faraz ~]# yum install xrdp  tigervnc-server
After installation you need to configure SELinux because you need change the file context by using command chconwhich stand for change context. Through this command change the SELinux security context of each file. You do not need to pay much attention to SELinux commands at this stage. Just use below commands
[root@faraz ~]# chcon  --type=bin_t  /usr/sbin/xrdp

[root@faraz ~]# chcon  --type=bin_t  /usr/sbin/xrdp-sesman
Now you are able to start the service of xrdp or you can set at boot time by using keyword enable.
[root@faraz ~]# systemctl start xrdp.service
If your firewall is running then stopfirewall by using command systemctl stop firewalld or make rule for xrdp with defining the port number 3389.
[root@faraz ~]# firewall-cmd   --permanent   --zone=public   --add-port=3389/tcp

[root@faraz ~]# firewall -cmd  --reload
Now your configuration is complete you can use Linux from any Windows machine by using remote desktop connection. Click on start button and write in the text area “Remote Desktop or mstsc” you will the application for remote connection click on it. Dialog box will open, enter the IP of Linux Server and click connect button.
mstsc remote access
mstsc remote access

You will see the xrdp login panel of session sesman-Xvnc enter username and password which is on Linux server choose any one or you can access from root also.
Xvnc sesman access to linux
Xvnc sesman access to linux
It may take a minute or depending on your machine.
xrdp remote windows
xrdp remote windows
We have successfully connected with xrdp Linux from Windows.

We have seen  it is very easy to install and  configure  xrdp. Only the technique of SELinux is required to change the security context of the file. 

No comments: