Skip to content

Instantly share code, notes, and snippets.

@leodutra
Created August 15, 2017 01:42
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save leodutra/3e44087f1896eac359aa9fc74a44766f to your computer and use it in GitHub Desktop.
Save leodutra/3e44087f1896eac359aa9fc74a44766f to your computer and use it in GitHub Desktop.
VirtualBox host-only network with bridged network

Create a host only network

Create a host only network with adapter address 192.168.56.1 and range from 192.168.56.101

Inside the guest

ifconfig eth1 192.168.56.101 netmask 255.255.255.0 up

And setup in /etc/network/interfaces:

auto eth0
auto eth1
iface eth0 inet dhcp
iface eth1 inet static
  address 192.168.56.101
  netmask 255.255.255.0
  network 192.168.56.0
  broadcast 192.168.56.255
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment