Revision history [back]

click to hide/show revision 1
initial version

How do you setup a subnet with DHCP, but without name-servers ?

When creating a subnet, you can optionally specify a list of name-servers that the DHCP agent will send to the instance. If you leave it blank, DHCP agent will send _its own_ address as the name-server. Is there a way to prevent this behavior ? That is, do not send any "domain-name-servers" option at all.

neutron net-create public ..
neutron subnet-create public 10.1.1.0/24 .. --dns-nameservers list=true 8.8.8.8 8.8.4.4
neutron net-create private ..
neutron subnet-create private 192.168.1.0/24 --no-gateway       # subnet without dns-nameservers

Example instance connected to two networks:

  • eth0 on public net - received 8.8.8.8,8.8.4.4 via "domain-name-servers" option
  • eth1 on private net - received 192.168.1.3 as the name-server. This is an IP of a controller running DHCP

Depending on the default OS settings, your /etc/resolv.conf may end up like:

search openstacklocal
nameserver 192.168.1.3

I would like the nameservers to be controlled by one network and use the DHCP on the other network for assigning an IP and mask only.