Fixing VirtualBox RDP Connection Issues: Windows 10, Kali Linux
In this article, we'll cover how to troubleshoot and fix Remote Desktop Protocol (RDP) connection issues when connecting from a Windows 10 Home machine to a Kali Linux virtual machine running on Ubuntu 24.04 LTS using VirtualBox.
Background
RDP is a widely used protocol for remotely connecting to a graphical interface of a computer over a network connection. In this scenario, we have two physical machines: one running Windows 10 Home, and the other running Ubuntu 24.04 LTS with VirtualBox installed and a Kali Linux virtual machine running inside it. We want to connect from the Windows 10 Home machine to the Kali Linux virtual machine using RDP.
Checking Pre-requisites
Before diving into troubleshooting connection issues, let's make sure that the required software and configurations are in place.
-
The
xrdppackage should be installed on the Kali Linux virtual machine. This package provides an implementation of the RDP protocol for Linux machines. - The Windows 10 Home machine should have an RDP client installed. This can be the built-in RDP client that comes with Windows, or a third-party client like Microsoft Remote Desktop.
- The Kali Linux virtual machine should be configured to use a bridged network adapter, so it can get its own IP address on the network.
Troubleshooting Connection Issues
If you're unable to establish an RDP connection from the Windows 10 Home machine to the Kali Linux virtual machine, here are some steps to help identify and fix the issue.
Step 1: Check Firewall Settings
Make sure that the firewall on the Kali Linux virtual machine is not blocking incoming RDP connections. By default, the ufw firewall on Kali Linux should allow incoming RDP connections on port 3389. You can check the firewall status using the following command:
sudo ufw status
If the firewall is blocking incoming RDP connections, you can allow them using the following command:
sudo ufw allow 3389/tcp
Step 2: Check VirtualBox Settings
Make sure that the VirtualBox settings for the Kali Linux virtual machine are configured correctly for RDP. Specifically, make sure that the "Remote Display" option is enabled and that the correct port number is specified.
Step 3: Check Network Settings
Make sure that the Kali Linux virtual machine is using a bridged network adapter and that it has been assigned a valid IP address on the network. You can check the IP address using the following command:
ip addr show
Step 4: Test Connectivity
Before attempting to connect using RDP, you can test connectivity between the Windows 10 Home machine and the Kali Linux virtual machine using the following command on the Windows machine:
ping <IP Address of Kali Linux VM>
-
Make sure that the
xrdppackage is installed on the Kali Linux virtual machine. - Make sure that the Windows 10 Home machine has an RDP client installed.
- Make sure that the Kali Linux virtual machine is using a bridged network adapter and that it has been assigned a valid IP address on the network.
- Check firewall settings on the Kali Linux virtual machine.
- Check VirtualBox settings for the Kali Linux virtual machine.
-
Test connectivity between the Windows 10 Home machine and the Kali Linux virtual machine using the
pingcommand.
References
- VirtualBox User Manual, Chapter 9: Remote Desktop Protocol, Oracle Corporation.
- "How to Install and Configure XRDP on Ubuntu 20.04", DigitalOcean Community.