为什么我不能使用远程桌面连接到VirtualBox?


12

这是我的设置:

  • 一切都在Mac OS X Snow Leopard下在一台计算机上运行。
  • 我在VirtualBox 3.0.10中运行Windows 7。
  • 在VirtualBox设置的“显示”,“远程显示”下,选中“启用服务器”,并保留默认端口(3389)。在“网络”下,我使用网桥适配器,因此VirtualBox像OS X一样使用DHCP获取IP。
  • 在VirtualBox中启动Windows后,我运行ipconfig并看到IP为192.168.0.181。
  • 从OS X命令行,我可以成功ping 192.168.0.181。

通过此设置,我希望能够启动远程桌面并连接到192.168.0.181。不幸的是,它无法正常工作,大约10秒钟后,Remote Desktop告诉我它无法连接到192.168.0.181。

为什么这行不通呢?

Answers:


6

在安装Extension Pack之前,我遇到了完全相同的问题。事实证明,即使文档听起来像是这样,VRDP扩展默认也不安装。

读取虚拟机的日志文件显示

00:00:00.230 VRDE:VirtualBox远程桌面扩展不可用。


5

不要连接到分配给在VirtualBox中运行的Windows的IP,而不要连接到主机,或者仅localhost连接到同一台计算机。这样,它就像一个魅力。


2
在网桥网络的情况下可以使用吗?我试过localhost127.0.0.1,但没有运气。但是连接到127.0.0.2就可以了(如这篇官方文章中所述)。
Jet

2

据我所知,我只是对其进行了重新测试。还要记住,您要连接的帐户必须具有密码。

您还必须在Windows 7中启用它,如下所示(从W7帮助中):

How do I allow remote connections on the computer I want to connect to?

If the computer you want to connect to is using Windows 7 Professional, 
Windows 7 Ultimate, or Windows 7 Enterprise, follow these steps:

Click to open System. 

In the left pane, click Remote settings.  If you are prompted for an administrator 
password or confirmation, type the password or provide confirmation. 

In the System Properties dialog box, under Remote Desktop, select one of the 
three options, and then click Select Users. 

If you are an administrator on the computer, your current user account will 
automatically be added to the list of remote users and you can skip the next two steps.

In the Remote Desktop Users dialog box, click Add.

In the Select Users or Groups dialog box, do the following:

To specify the search location, click Locations, and then select the 
location you want to search.

In Enter the object names to select, type the name of the user that you 
want to add, and then click OK. 

The name will be displayed in the list of users in the Remote Desktop 
Users dialog box.

是的,这是一种实现方法:让Windows处理远程桌面连接。但是使用VirtualBox,VirtualBox本身可以处理远程桌面连接,这就是为什么您应该连接到主机的IP,而不是Windows的IP(请参阅我对此的答复)的原因。
avernet

Windows仍需要配置为接受RDP连接,无论在何处处理连接。
Joe Internet,2009年

谢谢,它有效。在来宾操作系统上完成此操作(将用户“所有人”添加到该列表中)之后,我刚刚在主机操作系统上启动了远程桌面客户端,并在其中写了“ 127.0.0.2:3389”(不是V7.0站点中所述的127.0.0.1),并且有效!(我的适配器也是Bridge适配器,安装了ext-pack。)
Jet

@avernet当我将VM设置中的端口更改为5050时,可以使用“ 127.0.0.2:5050”连接到它。因此,可能Virtualbox处理连接。
Jet

2

检查Windows是否启用了防火墙,将其禁用将允许远程连接。使用桥接网络设置时,您必须连接到来宾(而不是主机)的IP。


是的,这对我有用。对话框立即寻找凭据。谢谢!
Chethan S.
By using our site, you acknowledge that you have read and understand our Cookie Policy and Privacy Policy.
Licensed under cc by-sa 3.0 with attribution required.