Page 1 of 1

Host-only networking no longer words after machine reinstallation

Posted: 23. Jul 2017, 22:37
by Paddy Landau
For various reasons, i had to reinstall Linux onto my machine (the host). I restored my Virtualbox guest on my new machine, but I cannot get the host-only networking mode to work.

Host: Linux Lubuntu 16.04 64-bit (fully updated)
Guest: Linux Ubuntu Server 14.04 64-bit (fully updated)

If I set the guest's networking to Bridged Adapter, the guest can access the internet, and my host is able to access the guest's website.
However, when I set the guest's networking to Host-only Adapter, the guest (obviously) cannot access the internet, but unfortunately my host cannot access the guest's website.
(This used to work before I had to reinstall Linux on my host.)

On the host

I have edited /etc/hosts to include the following lines (where acme.com is the name of the website).

Code: Select all

192.168.56.101    acme.com
192.168.56.101    www.acme.com
In Virtualbox

File > Preferences > Network > Host-only Networks…
I created a new host-only network, with the following settings.
  • Adapter: I used the default settings as follows.
    IPv4 Address: 192.168.56.1
    IPv4 Network Mask: 255.255.255.0
    IPv6 Address: (blank)
    IPv6 Prefix Length: (blank)
  • DHCP Server:
    Enable Server
    Server Address: 192.168.56.100
    Server Mask: 255.255.255.0
    Lower Address Bound: 192.168.56.101
    Upper Address Bound: 192.168.56.254
In the guest settings

Settings > Network > Adapter 1…
Enable Network Adapter
Attached to: Host-only Adapter
Name: vboxnet0
Advanced…
Adapter Type: Intel PRO/1000 MT Desktop (82540EM)
Promiscuous Mode: Deny
MAC Address: 0800270726DD (randomly generated)
Cable Connected

In the guest itself

I have tried two modes.

Mode 1:
Running as default. ifconfig (in the guest) shows IP address 192.168.56.101.

Mode 2:
Edit the guest's /etc/network/interfaces to use a static IP address 192.168.56.66, and the host's /etc/hosts to use 192.168.56.66 instead of 192.168.56.101. ifconfig (in the guest) shows IP address 192.168.56.66.

In both modes, the host is unable to see the guest's website.

What am I doing wrong, and how can I fix it, please?

Re: Host-only networking no longer words after machine reinstallation

Posted: 23. Jul 2017, 23:07
by socratis

Re: Host-only networking no longer words after machine reinstallation

Posted: 24. Jul 2017, 14:47
by Paddy Landau
socratis wrote:Take a look at #16911: hostonly network broken on 5.1.24
Thank you! I have installed the test build as instructed in the bug report, and it works again. Phew!