0

I have a PC with Windows 8, with Oracle VirtualBox installed on it. In the File>Preferences>Network menu in VirtualBox, I have created three host-only networks:

  1. Host-only network 1 - 10.10.10.1
  2. Host-only network 2 - 10.20.20.1
  3. Host-only network 3 - 192.168.100.1

with all of them having a netmask 255.255.255.0.

I have also created three VMs as listed below:

  1. Controller is attached to Host-only network adapter 1 on the first adapter and NAT on the second.
  2. Network is attached to Host-only network adapter 2 on the first adapter and Host-only network adapter 3 on the second.
  3. Compute is attached to Host-only network adapter 3 on the first adapter and Host-only network adapter 2 on the second.

On the controller node, I configured the settings as per below:

  • In /etc/hosts: Added 10.10.10.11 as controller, 10.10.10.11 as network and 10.10.10.13 as compute
  • In /etc/network/interfaces:

    auto eth0
        iface eth0 inet static
        address 10.10.10.10
        netmask 255.255.255.0
    
    auto eth0
    iface eth0 inet dhcp
    
  • In /etc/resolv.conf: Added 8.8.8.8 as nameserver

The problem is that Internet connectivity does not seem to work. apt-get update fails to fetch index files from every server and ping google.com returns unknown host google.com.

How can I fix internet connectivity?

0

You might have configured the wrong network interface in Controller's /etc/network/interfaces. Find the correct network interface name and modify /etc/network/interfaces, replacing eth1 with the correct interface name:

auto eth1
iface eth1 net dhcp

You might also want to remove one of the two stanzas in /etc/network/interfaces, either:

auto eth0
iface eth0 inet static
    address 10.10.10.10
    netmask 255.255.255.0

OR

auto eth0
iface eth0 inet dhcp

as they might conflict.

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.