[Solved] set DNS to hosts static vboxnet0 address
Posted: 23. Jan 2018, 17:09
My setup:
I have two virtual machines running on virtualbox which is on a Mint host.
The two virtual machines are connected to a host-only network: vboxnet0
The DHCP server for vboxnet0, is set on one of the virtualmachines, using nethserver.
This nethserver also does the DNS.
The idea is that the other guest OS, gets dhcp, domain, AD etc from nethserver.
(Nethserver itself connects to the internet using a bridged connection on the wireless interface. )
This works.
From nethserver CLI, I can ping, and I can find that machine doing nslookup, using the IP, and reverse, using the hostname.
The problem:
I can't connect to the guest OS's using the hostname
My host system can ping both the guests.
However, when I try to do a nslookup, I get the NXDOMAIN reply, because the host only looks at 127.0.0.1
The vboxnet address on the host is static so it doesn't get the DNS data from the Guest.
In Virtualbox, it's not possible to set the DNS for vboxnet0 static config. (Using the GUI)
Is this possible using the CLI with vboxmanage?
Should I use another network type?
- Bridged may be an option, but then I need an external switch. Since I want to duplicate this setup a number of times, I want to avoid external hardware.
thoughts?
I have two virtual machines running on virtualbox which is on a Mint host.
The two virtual machines are connected to a host-only network: vboxnet0
The DHCP server for vboxnet0, is set on one of the virtualmachines, using nethserver.
This nethserver also does the DNS.
The idea is that the other guest OS, gets dhcp, domain, AD etc from nethserver.
(Nethserver itself connects to the internet using a bridged connection on the wireless interface. )
This works.
From nethserver CLI, I can ping, and I can find that machine doing nslookup, using the IP, and reverse, using the hostname.
The problem:
I can't connect to the guest OS's using the hostname
My host system can ping both the guests.
However, when I try to do a nslookup, I get the NXDOMAIN reply, because the host only looks at 127.0.0.1
The vboxnet address on the host is static so it doesn't get the DNS data from the Guest.
In Virtualbox, it's not possible to set the DNS for vboxnet0 static config. (Using the GUI)
Is this possible using the CLI with vboxmanage?
Should I use another network type?
- Bridged may be an option, but then I need an external switch. Since I want to duplicate this setup a number of times, I want to avoid external hardware.
thoughts?