<html><body>
        <div dir="ltr">Geert, I'm fully aware that a CNAME is DNS, and dhcp-host is not, but DNS and DHCP do work together in dnsmasq in various ways.<br></div><div dir="ltr">This is why I quoted the statement from <a href="http://www.thekelleys.org.uk/dnsmasq/docs/dnsmasq-man.html">http://www.thekelleys.org.uk/dnsmasq/docs/dnsmasq-man.html</a> in the dhcp-host option which specifically says to look at the documentation for --cname if you want to have an alias for a host.</div><div dir="ltr"><br></div><div dir="ltr">I'm pretty sure I'm misunderstanding some part of the documentation. Perhaps it's trying to say if you are using dhcp-host to create DNS records for a host, you can use CNAME to alias another name to it via DNS, which seems too obvious to bother mentioning, but maybe that's all it's saying.</div><div dir="ltr">When I read that statement I understood that if you created a CNAME that the DHCP server would use it to alias the name as well, but maybe that's not the case.</div><div dir="ltr"><br></div><div dir="ltr"><br>
    <div class="gmail_quote">
        <div dir="ltr" class="gmail_attr" style="">On Dec 23, 2020 at 16:13:45, Geert Stappers <<a href="mailto:stappers@stappers.nl">stappers@stappers.nl</a>> wrote:<br></div>
        <blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-style:solid;border-left-color:rgb(204,204,204);padding-left:1ex">
            


    On Wed, Dec 23, 2020 at 12:08:32PM -0600, Arthur Wiebe wrote:<br><blockquote type="cite" style=""> >From reading the man page, and my understanding of the statement "Only one<br></blockquote><blockquote type="cite" style=""> hostname can be given in a --dhcp-host option, but aliases are possible by<br></blockquote><blockquote type="cite" style=""> using CNAMEs. (See --cname )" I've been attempting to implement this<br></blockquote><blockquote type="cite" style=""> without any success so far.<br></blockquote><blockquote type="cite" style=""> <br></blockquote><blockquote type="cite" style=""> My goal is to have two names get assigned the same IP via DHCP. The purpose<br></blockquote><blockquote type="cite" style=""> of this is transitioning IPSec IDs as I have strongswan using dnsmasq to<br></blockquote><blockquote type="cite" style=""> assign static IPs to mobile clients.<br></blockquote><blockquote type="cite" style=""> <br></blockquote><blockquote type="cite" style=""> In this example I would like both DEVICE_V1 and DEVICE_V2 to get the same<br></blockquote><blockquote type="cite" style=""> IP address 10.1.2.3 and my current attempted configuration is as follows.<br></blockquote><blockquote type="cite" style=""> <br></blockquote><blockquote type="cite" style=""> /etc/hosts contains:<br></blockquote><blockquote type="cite" style=""> <br></blockquote><blockquote type="cite" style=""> 10.1.2.3 DEVICE_V1<br></blockquote><blockquote type="cite" style=""> <br></blockquote><blockquote type="cite" style=""> --<br></blockquote><blockquote type="cite" style=""> <br></blockquote><blockquote type="cite" style=""> dnsmasq conf file contains:<br></blockquote><blockquote type="cite" style=""> <br></blockquote><blockquote type="cite" style=""> cname=DEVICE_V2,DEVICE_V1<br></blockquote><blockquote type="cite" style=""> dhcp-host=DEVICE_V1,10.1.2.3,infinite<br></blockquote><blockquote type="cite" style=""> <br></blockquote><blockquote type="cite" style=""> --<br></blockquote><blockquote type="cite" style=""> <br></blockquote><blockquote type="cite" style=""> I've tried variations including defining both IDs in the hosts file as<br></blockquote><blockquote type="cite" style=""> follows and adding "host-record" conf options for DEVICE_V1 but neither<br></blockquote><blockquote type="cite" style=""> made a difference.<br></blockquote><blockquote type="cite" style=""> 10.1.2.3 DEVICE_V1 DEVICE_V2<br></blockquote><blockquote type="cite" style=""> <br></blockquote><blockquote type="cite" style=""> So far no matter what I've tried only the ID specified in the dhcp-host<br></blockquote><blockquote type="cite" style=""> option actually gets an IP.<br></blockquote><blockquote type="cite" style=""> In the dnsmasq log I get the following message for DEVICE_V2.<br></blockquote><blockquote type="cite" style=""> client provides name: DEVICE_V2<br></blockquote><blockquote type="cite" style=""> DHCPDISCOVER(eth0) 00:11:22:33:44:55 no address available<br></blockquote><blockquote type="cite" style=""> <br></blockquote><blockquote type="cite" style=""> I'd love either some clarification on how this is supposed to work<br></blockquote><br>[0]<br><br>`cname`  is DNS,   `dhcp-host` is not DNS.<br><br><br><blockquote type="cite" style=""> or perhaps this is a bug in dnsmasq 2.80?<br></blockquote><br><a href="http://www.catb.org/esr/faqs/smart-questions.html#idm368">http://www.catb.org/esr/faqs/smart-questions.html#idm368</a><br><br><br>Regards<br>Geert Stappers<br><br>[0] Not my smartest move for choosing to write an email when having no<br>    time to write an email ...<br>-- <br>Silence is hard to parse<br><br>_______________________________________________<br>Dnsmasq-discuss mailing list<br><a href="mailto:Dnsmasq-discuss@lists.thekelleys.org.uk">Dnsmasq-discuss@lists.thekelleys.org.uk</a><br><a href="http://lists.thekelleys.org.uk/mailman/listinfo/dnsmasq-discuss">http://lists.thekelleys.org.uk/mailman/listinfo/dnsmasq-discuss</a><br>


        </blockquote>
    </div>
</div>
    
</body></html>