How To Remote Desktop from windows to Linux
After installing Linux in a production or testing environment many users struggle to find a way on How to Remote Desktop from windows to Linux machine.
- For new Linux users it might not be less than a challenge.
Here in this guide we are going to install Linux Remote Desktop Client (XRDP) which is an open source remote desktop protocol.
Linux remote desktop protocol XRDP allows you to access any Linux based machine right from your windows desktop using RDP Protocol, It will show your Linux Graphical User Interface on your windows machine.
I will show you how to install & setup Linux Remote Desktop (XRDP) on CentOS7/RHEL 7. The installation process is quite simple; you just need to follow below steps.
Note: XRDP is not available on official repository of CentOS7/RHEL7.
We need to download and add EPEL (Extra Packages Enterprise Linux).
Install EPEL repository on CentOs/RHEL 7 directly from internet.
- Both 32-bit and 64-bit packages are available.
For RHEL7 or CentOS7 7.x 32-bit
rpm -ivh http://download.fedoraproject.org/pub/epel/6/i386/epel-release-6-8.noarch.rpm
For RHEL7 or CentOS7 7.x 64-bit
rpm -ivh http://download.fedoraproject.org/pub/epel/6/x86_64/epel-release-6-8.noarch.rpm
After Installing EPEL Repository on your linux box, Now letâ€™s move on the real action.
Step 2: Remote Desktop Linux Client (XRDP)
Run the below command in linux terminal window.
yum install xrdp tigervnc-server -y
Step 3: Start XRDP Service
systemctl start xrdp
Check port 3389 is in listening mode, to make sure XDRP service is up and running Use the following command.
netstat -antlup | grep xrdp
Step 4: Enable XRDP Service at Startup
systemctl enable xrdp
Step 5: Allow 3389 Port in the Linux Firewall
Add rule for remote desktop port 3389 in Linux Firewall.
firewall-cmd --permanent --zone=public --add-port=3389/tcp
Step 6: Configure SELinux to allow XRDP
chcon --type=bin_t /usr/sbin/xrdp
chcon --type=bin_t /usr/sbin/xrdp-sesman
Step 7: Test Remote Desktop Connection from Windows to Your Linux Machine.
Now back on your windows and open Remote Desktop Connection Window by typing mstsc in Run command box.
First type the IP Address of Linux Machine and then click Connect Next you need to Provide username and password of your Linux machine and hit ok.(you can use root or any other user credentials).
After some startup settings, you will get a desktop of your Linux machine on your windows PC
That’s all, we have successfully setup remote desktop feature on CentOS7. Don’t forget to leave your valuable feedback by submitting in the comments section or sending us an email at firstname.lastname@example.org.