If you have Rocky Linux 8 desktop and Windows 7/10/11 in a local environment and want to access using the RDP- Remote desktop protocol, then here is the way.
To connect Linux operating systems such as Rocky Linux, AlmaLinux 8, or CentOS, we can use the open-source implementation of Remote desktop protocol called XRDP. RDP is developed by Microsoft and has been an integral part of Windows operating systems. It allows the users to remotely control and use the GUI desktop systems just like a local one. Although, Windows can be operated over this protocol out of the box, for Linux we need to install some additional packages. Here we learn how to set up a remote desktop connect to Rocky Linux 8.
- Access Rocky Linux 8 Remote Desktop using Windows 7/10/11 RDP
Access Rocky Linux 8 Remote Desktop using Windows 7/10/11 RDP
The given guide can be used for Rocky Linux, Almalinux, CentOS 8/7, RHEL 8/7, Oracle Linux, and other similar RHEL based operating systems.
Note: Your Linux must be running on a Graphical user interface, if not then see given how-tos.
- How to install Gnome GUI on Rocky or Almalinux 8
- Steps to Install Xfce Desktop on Rocky Linux
- Install KDE Plasma Desktop on Rocky Linux 8…
1. Add Epel Repository on Rocky Linux
The packages to install XRDP on Rocky Linux are not available via the default App stream repository of the operating system. Hence, first, we have to enable the EPEL- Extra Packages for Enterprise Linux repository using the below-given command:
sudo dnf install epel-release
2. Run system update
Issue the update command once, to refresh the system cache and update already installed Linux packages to their latest versions.
sudo dnf update
3. Install XRDP on Rocky Linux or AlmaLinux 8
As at the beginning of the article, we already have discusses that XRDP is the open-source implementation of the Microsoft RDP, it uses port number 3389 to establish a connection. And of course, it is not available out of the box like Windows on Linux system, therefore, we manually need to set it up. Use the below-given command:
sudo dnf install xrdp
4. Start and Enable XRDP service
To make sure the Xrdp service will start automatically whenever the system boots, we have to enable the same. Therefore, first, start and then enable the service using the given command:
sudo systemctl start xrdp sudo systemctl enable xrdp
To check the service is running fine without any errors, use this one:
systemctl status xrdp
5. Allow port 3389 in the firewall
If you have an activated firewall on your Rocky or other RHEL based Linux you are using then to connect it over Remote desktop protocol, allow port 3389 through the firewall.
#Add Firewall firewall-cmd --permanent --add-port=3389/tcp #Reload Firewall service firewall-cmd --reload
6. Log out Linux session
Now, log out your current Rocky Linux session, so that we can access it on Windows using its Remote desktop application.
7. Run Windows 7/8//10/11/server Remote Desktop
Now, go to your Windows operating system and search to open Remote Desktop Application. Alternatively, you can use the RUN box. Press the Win+R key and type-
mstsc.exe after that hit the Enter key.
Once you have the Remote Desktop Connection box, enter your remote Linux IP address, here it is for Rocky Linux.
8. Login Rocky Linux Remote Desktop
Once the connection is established you will have the Xvnc window to enter the username and password of the remote Linux operating system. Enter that and hit the OK button.
Finally, you can use your remote Linux graphical user interface on Windows using the Remote desktop protocol.