1

I have created a VM image (Ubuntu 16.04.6) in VBox on Windows and wanted to access it outside the host in my network. I am facing challenge in achieving this.

These are the steps i followed:

  • created the "host-only network" by using Host network manager.
  • configured two adapters, first adapter is attached to NAT and the second is attached to Host-only Adapter.
  • set up the network interface file to point to host-only adapter and assigned a static IP.
  • restarting VM image.

I can access VM image from the host using the static ip. But the challenge is that i can not expose this vm outside my machine as its not accessible. I also tried to set the default gateway to that of our network, but it won't work. In fact that gateway is not accessible from the vm though its accessible from the host machine.

How can this access issue be fixed? Any suggestions/pointers are most welcome.

Thanks in Advance!

  • If you can access the VM from the host the problem is on the host, which is windows. You "could" get around the need to mess with routing on windows by simply using a bridged adapter and giving the VM an ip address from your network DHCP server. – Dave Jan 13 at 18:15
2

I set the network adapter type to "Bridged Adapter". Then the VM gets its own IP address on the LAN and can be accessed using that.

enter image description here

| improve this answer | |
  • I have set up a network adapter type to "Bridged Adapter", I have select the name of the network "Realtek PCIs GbE Family Controller" (I can see only two option "Realtek PCIs GbE Family Controller" and "Hyper-V Virtual Ethernet Adaptor") and left the default settings but it is not working – Swapnil Shelke Jan 23 at 6:28
  • @SwapnilShelke I'm sorry it does not work for you, it works for me on several virtual machines. I have added a screenshot showing the detailed settings I use. – Organic Marble Jan 23 at 13:31

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.