DNS forwarding not working where WAN routing set to DHCP interface


#1

Hello everyone,
Firstly I am very excited about VyOS and am glad I found it. Congrats to all the people who put the hard work in for it to get to where it is today.

Now, I have a virtual network I have setup on my laptop where I essentially want all my virtual devices to have an IP address from a local DHCP server on the host irrespective whether the host has a WAN/LAN connection or not so I can connect to my various virtual machines at will, nor do I want to manually maintain IP addresses hence the DHCP server. I guess the last note is NO IPv6. All is over IPv4.

The problem is that I cannot get the DNS forwarding to work. What I’d like is for DHCP to obtain the DNS settings from the network that it is connected to and I want the DNS forwarding to forward those DNS server address(es) across to the virtual network.

More information included in the diagram below.

Can anyone shed any ideas please? Thank in advance. Much appreciated indeed.

[code]VyOS Virtual Router
Config:

set interfaces ethernet eth0 address dhcp
set interfaces ethernet eth1 address 10.1.1.1/24
set nat source rule 1 outbound-interface eth0 source address 10.1.1.0/24 translation address masquerade
set protocols static interface-route 0.0.0.0/0 next-hop-interface eth0
set service dhcp-server shared-network-name vmnet subnet 10.1.1.0/24 start 10.1.1.200 stop 10.1.1.254
set service dhcp-server shared-network-name vmnet subnet 10.1.1.0/24 default-router 10.1.1.1

set dns forwarding dhcp eth0 listen-on eth1[/code]


#2

shouldn’t the network address and subnet be 10.1.1.0/24 ? also, you probably don’t need a static interface route, because I assume the dhcp server will hand out a default route to the VyOS instance on eth0.


#3

Sorry, that was a typo as I re-wrote the configuration for the post. What’s on the router is actually exactly that, 10.1.1.0/24. I modified the original post to reflect the correct configuration.

So, with respect to the question, are you saying that the reason why it might not be working now is because I’ve got a static route for WAN?