求助VirtualBox网络配置hostonly模式时主机不能访问虚拟机但是虚拟机互相访问正常
-------------------------------------------------------------------------------------------------
系统主机1中有两个VirtualBox虚拟机1-2 均采用hostonly模式 其中主机和虚拟机配置如下:
(1)主机1 windows 10 静态IP地址203.8x.xxx.122 虚拟网卡是192.168.56.1 开户了DHCP功能,可让虚拟机自动获得IP地址
(2)虚拟机1 ubuntu Server17.04 IP:192.168.56.101 安装了apache2+PHP 并开通了80
(3)虚拟机2 windows2003Server IP :192.168.56.102 安装了IIS+ASP并开通了80
------------------------------------------------------------------------------------------------------
问题来了 主机1可以ping通虚拟机2和虚拟机3但是不能通过WEB访问虚拟机的网站 网页打不开
但是 虚拟机1和虚拟机2之间互相访问对方的网站是正常的能找开网页
我想知道如何解决这个问题。请大侠多多帮助,非常急。
如果解决这个问题。我免费提供1G的网页空间并解析给您使用。立即兑现。再次感谢
求助VirtualBox网络配置hostonly模式时主机不能访问虚拟机但是虚拟机互相访问正常
-
- 帖子: 51
- 注册时间: 2013-09-08 19:01
- 系统: ubuntu-desktop17.04
- 来自: 广州天河区
- 联系:
-
- 论坛版主
- 帖子: 18279
- 注册时间: 2009-08-04 16:33
-
- 帖子: 51
- 注册时间: 2013-09-08 19:01
- 系统: ubuntu-desktop17.04
- 来自: 广州天河区
- 联系:
Re: 求助VirtualBox网络配置hostonly模式时主机不能访问虚拟机但是虚拟机互相访问正常
大侠。我说的问题。能不能解决poloshiao 写了:http://www.virtualbox.org/manual/ch06.h ... k_hostonly
Host-only networking
希望给一下提示。万分感激
-
- 论坛版主
- 帖子: 18279
- 注册时间: 2009-08-04 16:33
Re: 求助VirtualBox网络配置hostonly模式时主机不能访问虚拟机但是虚拟机互相访问正常
问题来了 主机1可以ping通虚拟机2和虚拟机3
1. http://www.virtualbox.org/manual/ch06.h ... k_hostonly但是 虚拟机1和虚拟机2之间互相访问对方的网站是正常的能找开网页
Host-only networking
It can be thought of as a hybrid between the bridged and internal networking modes
as with bridged networking, the virtual machines can talk to each other and the host as if they were connected through a physical Ethernet switch.
1-1. 你所描述的就是 Host-only 的前述功能之一
但是不能通过WEB访问虚拟机的网站 网页打不开
2. 先確定 從 虚拟机1 可以成功 瀏覽 虚拟机1 的网页虚拟机1 ubuntu Server17.04 IP:192.168.56.101 安装了apache2+PHP 并开通了80
2-1. http://127.0.0.1/index.php (或 http://127.0.1.1/index.php)
2-2. http://localhost/index.php (或 其它合適 index.* 例如 index.html)
3. 如果 2-1 可以 2-2 不行
檢查一下 虚拟机1 的 DNS
3-1. 如果 2-1 也不行
應該檢查你的 apache2 的 設定檔
4. 如果 2-1, 2-2 都可以
表示 你需要在 Host 建立 NAT 機制
http://www.virtualbox.org/manual/ch06.h ... at_service
Network Address Translation Service