Server Fault is a question and answer site for system and network administrators. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I've got two vms running on a windows host, each with a host-only network and ips in the 192.168.56.XXX range. One of them is running apache and serving some content that I want to access from my windows host.

However, the windows host can't access the apache server at all. The server is running on ipconfig from windows says it's ip for the Virtual Box interface is I tried route add to route 192.168.56.XX traffic, but everything I tried didn't work and I was probably using it wrong.

Any ideas on how to make this work?

share|improve this question

If you want to communicate with your VMs with 192.168.56.XXX IP, you need the host Virtual Box interface to have an IP on the same range. Your interface don't (169.254).

On a fresh installation of VBox 3.1.8, it creates a new interface named "VirtualBox Host-Only Network" with a static IP address of :

Your interface is most probably misconfigured to use DHCP. Change it to use with netmask and it should work.

share|improve this answer

Your VMs are getting IPs like 169.* because their DHCP clients are not finding a DHCP server to give them a lease. Therefore, the IP of the host & IPs of the VMs are not accessible to each other. A static route won't really solve this. You need to figure out why the VMs are not getting an IP lease, or you could try manually setting the IP addresses to the same private Class C (192.168.56.*) that your host is on.

share|improve this answer

I was able to fix this by giving my server a static address of Then, I was able to ping my guest OS from the host. I also added a host file entry on my host machine to make it easier to access.

I'm still unable to ping the host from the guest... not sure why.

share|improve this answer

Have you set the correct default gateway in your VM? What's the routing table look like on host and guest?

share|improve this answer

Once you find, install and start the Host-only adapter on your Windows host, if you still can't connect to the VMs, try turning off the Windows firewall for that adapter.

If that works, you can either leave it that way, or use your Windows Firewall-fu to open the correct ports and stuff.

share|improve this answer

169.254 = No DHCP server found. THis could be either there isnt one or there is a firewalling issue. Depending on your operating system it would also be advisable to check your firewall rules. Windows 7 is quite paranoid!

share|improve this answer

If you can't ping host from VM, have you try to turn off firewall on host? perhaps it's filtering ICMP request. Turn off the firewall as test, if ping is OK then you should check your firewall configuration that filter ICMP request.

share|improve this answer

try this:

BTW, could not use powershell script. I needed to create *NdisDeviceType key via Regedit

share|improve this answer
Welcome to Server Fault! Generally we like answers on the site to be able to stand on their own - Links are great, but if that link ever breaks the answer should have enough information to still be helpful. Please consider editing your answer to include more detail. See the FAQ for more info. – slm Apr 4 '13 at 18:00

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.