7 Remote virtual machines The actual port used by a running VM can be either queried with VBoxManage showvminfo command or seen in the GUI on the “Runtime” tab of the “Session Information Dialog”, which is accessible via the “Machine” menu of the VM window. Here follow examples for the most common RDP viewers: On Windows, you can use the Microsoft Terminal Services Connector (mstsc.exe) that ships with Windows. You can start it by bringing up the “Run” dialog (press the Windows key and “R”) and typing “mstsc”. You can also find it under “Start” - “All Programs” - “Accessories” - “Remote Desktop Connection”. If you use the “Run” dialog, you can type in options directly: mstsc 1.2.3.4[:3389] Replace “1.2.3.4” with the host IP address, and 3389 with a different port if necessary. Note: When connecting to localhost in order to test the connection, the addresses localhost and 127.0.0.1 might not work using mstsc.exe. Instead, the address 127.0.0.2[:3389] has to be used. On other systems, you can use the standard open-source rdesktop program. This ships with most Linux distributions, but VirtualBox also comes with a modified variant of rdesk- top for remote USB support (see chapter 7.1.4, Remote USB, page 93 below). With rdesktop, use a command line such as the following: rdesktop -a 16 -N 1.2.3.4:3389 As said for the Microsoft viewer above, replace “1.2.3.4” with the host IP address, and 3389 with a different port if necessary. The -a 16 option requests a color depth of 16 bits per pixel, which we recommend. (For best performance, after installation of the guest operating system, you should set its display color depth to the same value). The -N option enables use of the NumPad keys. If you run the KDE desktop, you might prefer krdc, the KDE RDP viewer. The command line would look like this: krdc --window --high-quality rdp:/1.2.3.4[:3389] Again, replace “1.2.3.4” with the host IP address, and 3389 with a different port if neces- sary. The “rdp:/“ bit is required with krdc to switch it into RDP mode. 7.1.2 VBoxHeadless, the remote desktop server While any VM started from the VirtualBox Manager is capable of running virtual machines re- motely, it is not convenient to have to run the full-fledged GUI if you never want to have VMs displayed locally in the first place. In particular, if you are running server hardware whose only purpose is to host VMs, and all your VMs are supposed to run remotely over VRDP, then it is pointless to have a graphical user interface on the server at all especially since, on a Linux or Solaris host, the VirtualBox manager comes with dependencies on the Qt and SDL libraries. This is inconvenient if you would rather not have the X Window system on your server at all. VirtualBox therefore comes with yet another front-end called VBoxHeadless, which produces no visible output on the host at all, but instead only delivers VRDP data. This front-end has no dependencies on the X Window system on Linux and Solaris hosts.1 To start a virtual machine with VBoxHeadless, you have two options: 1Before VirtualBox 1.6, the headless server was called VBoxVRDP. For the sake of backwards compatibility, the VirtualBox installation still installs an executable with that name as well. 91
Previous Page Next Page