Troubleshooting: VirtualBox VRDE Remote Desktop Connections

Running a virtual machine in VirtualBox, you have two options accessing it via a remote desktop protocol (RDP) connection: running a RDP server on the virtual machine itself (e.g. the RDP server integrated in Windows Pro versions) or connecting on machine level via VirtualBox VRDE, which is compatible to Microsoft RDP.

This article should help you troubleshooting non-working VRDE connections.

Given a working VirtualBox installation and virtual machine, you should check the following steps to make sure VRDE is working properly. These steps are verified with VirtualBox 5.1 and a Windows 10 Pro VM, but should work with other VirtualBox and/or guest OS versions as well. Hint: If you are running VirtualBox VMs via VBoxVmService, read step 8 first.

  1. The matching version of the VirtualBox Extension Pack should be installed on the host system. This is a separate download on the VirtualBox download site.
  2. VRDE should be activated for the guest. If you are running VBoxVMService, make sure that the VBoxVMService is stopped when making changes to a VM (see last step). There are two ways of changing the VM’s VRDE settings:
    • VirtualBox GUI: Select the VM, click Change > Display > Remote Display. Check “Enable server” and choose an appropriate port, e.g. 3390.
    • Console: Type vboxmanage list vms and then vboxmanage showvminfo “MyVMName” (replace MyVMName accordingly). There should be an entry VRDE: enabled (Address: 0.0.0.0, Ports 3390, …). If not, you can change the VM settings via vboxmanage modifyvm “MyVMName” –vrde on and vboxmanage modifyvm “MyVMName” –vrdeport 3390.
  3. Choose an appropriate VRDE port for the VM. If you are running multiple VMs, use a separate port for each VM. Make sure you don’t specify already used ports. Especially omit port 3389 on a Windows Pro system as the integrated RDP server is already listening on this port.
  4. The VRDE ports must not be blocked by a firewall on the host system. Depending on how you run the VM, open the port for incoming connections to the VBoxManage and/or VBoxHeadless executable.
  5. Make sure VBoxManage or VBoxHeadless are listening on the chosen VRDE port on the host system when the VM is running. On a Windows host you can do this by opening the console (cmd.exe) and typing netstat -ano.
  6. When you are trying to connect remotely, make sure you are using the correct IP and port. Given a example host system with IP 192.168.1.40 and a guest with VRDE port 3390, you would have to connect to 192.168.1.40:3390.
  7. Make sure the VirtualBox Guest Additions are installed on the VM. This can be done by running the VM in the GUI and choosing Devices > Install Guest Additions from the menu. This inserts a virtual CD ROM containing the Guest Additions installer.
  8. If you are running the VM as a service via VBoxVmService:
    • You can specify VRDE options in the VBoxVmService.ini (this INI is in the VBoxVmService installation path). For the corresponding VM block, add the lines Vrde=on and VrdePort=3390.
    • You have to make sure that the guest settings have VRDE enabled regardless of the settings you specify in the VBoxVmService.ini. However, guest settings cannot permanently edited when the VBoxVmService is running (described here). It is important to perform step 2 of this article with the VBoxVmService stopped.

I hope this article was helpful for you. Your comment and feedback is appreciated!

Advertisements

One thought on “Troubleshooting: VirtualBox VRDE Remote Desktop Connections

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s