When multiple dhcp agents per network, each agent doesn't provide all agent ips for nameserver

Bug #1259482 reported by Sylvain Afchain
16
This bug affects 3 people
Affects Status Importance Assigned to Milestone
neutron
Fix Released
Medium
Sylvain Afchain
Havana
Fix Released
Undecided
Unassigned

Bug Description

When we have a setup with multiple dhcp agents per network, dnsmasq doesn't provide nameserver entries with all the ip addresses of the dnsmasq related to the subnet. Thus if the unique agent which has been used as nameserver fail, the VMs are unable to resolv domains.

This bug is related to this one https://bugs.launchpad.net/neutron/+bug/1242712, but doesn't address exactly the same thing.

Changed in neutron:
assignee: nobody → Sylvain Afchain (sylvain-afchain)
description: updated
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to neutron (master)

Fix proposed to branch: master
Review: https://review.openstack.org/61067

Changed in neutron:
status: New → In Progress
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to neutron (master)

Reviewed: https://review.openstack.org/61067
Committed: https://git.openstack.org/cgit/openstack/neutron/commit/?id=2afff147c45f97a0809db40ad072332fb37ccd8d
Submitter: Jenkins
Branch: master

commit 2afff147c45f97a0809db40ad072332fb37ccd8d
Author: Sylvain Afchain <email address hidden>
Date: Wed Dec 4 21:01:06 2013 +0100

    Dnsmasq uses all agent IPs as nameservers

    Add dhcp option which provides all agent IPs
    which will be used as nameserver entries when
    neutron uses multiple dhcp agent per network and
    when there is no dns nameserver provided by the
    neutron server.

    Change-Id: I639a844bba212a731616851ff479a5e735612cf8
    Closes-bug: #1259482

Changed in neutron:
status: In Progress → Fix Committed
Revision history for this message
Kevin Bringard (kbringard) wrote :

An additional thought on this... are we sure that simply pushing out all the DHCP IPs resolves this issue in all cases? Won't it rely on the client retrying in the event of the first server returning an NXDOMAIN?

It's dnsmasq specific, but I've attached a patch I was working on (probably could use additional review), which writes out an add-hosts file to all dhcp agents and adds --addn-hosts= to the dnsmasq process. This causes all dnsmasq agents to check that hosts file and return a record it finds in there, even if it isn't the process which handed out the lease (which is why it will sometimes return records and other times not, even if the lease is in its leases file).

I could be wrong, just asking the question to make sure we're covering all of our bases.

Revision history for this message
John Dewey (retr0h) wrote :

Yeah, I don't believe this patch works as intended.

The resolver will use the first name server entry in resolv.conf. It will try an alternate name server upon timeout. NXDOMAIN is a valid response, thus not working the way you are expecting.

Revision history for this message
Kevin Bringard (kbringard) wrote :

Sorry, ignore my comment, I didn't do my due diligence and read the other referenced bug, which addresses the issue I was talking about.

Changed in neutron:
importance: Undecided → Medium
milestone: none → icehouse-3
Thierry Carrez (ttx)
Changed in neutron:
status: Fix Committed → Fix Released
Thierry Carrez (ttx)
Changed in neutron:
milestone: icehouse-3 → 2014.1
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to neutron (stable/havana)

Fix proposed to branch: stable/havana
Review: https://review.openstack.org/111294

tags: added: havana-backport-potential
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to neutron (stable/havana)

Reviewed: https://review.openstack.org/111294
Committed: https://git.openstack.org/cgit/openstack/neutron/commit/?id=72fad73d5f8f44edd5b5cd8a8ecb682fe8026d5d
Submitter: Jenkins
Branch: stable/havana

commit 72fad73d5f8f44edd5b5cd8a8ecb682fe8026d5d
Author: Sylvain Afchain <email address hidden>
Date: Wed Dec 4 21:01:06 2013 +0100

    Dnsmasq uses all agent IPs as nameservers

    Add dhcp option which provides all agent IPs
    which will be used as nameserver entries when
    neutron uses multiple dhcp agent per network and
    when there is no dns nameserver provided by the
    neutron server.

    Change-Id: I639a844bba212a731616851ff479a5e735612cf8
    Closes-bug: #1259482
    (cherry picked from commit 2afff147c45f97a0809db40ad072332fb37ccd8d)

tags: added: in-stable-havana
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.