<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=us-ascii">
<style type="text/css" style="display:none;"> P {margin-top:0;margin-bottom:0;} </style>
</head>
<body dir="ltr">
<div style="font-family: "Segoe UI", "Helvetica Neue", sans-serif; font-size: 9pt; color: rgb(0, 0, 0);">
Thank you for your help, but no luck I'm afraid. The Windows 7 VM is still being provided with a 192.168.0.104 IP address even though the MAC address is 08:00:27:ab:8b:7e.</div>
<div style="font-family: "Segoe UI", "Helvetica Neue", sans-serif; font-size: 9pt; color: rgb(0, 0, 0);">
<br>
</div>
<div style="font-family: "Segoe UI", "Helvetica Neue", sans-serif; font-size: 9pt; color: rgb(0, 0, 0);">
I can see that the Windows 7 VM is requesting 104. Perhaps Dnsmasq is honouring that and ignoring the config file?</div>
<div style="font-family: "Segoe UI", "Helvetica Neue", sans-serif; font-size: 9pt; color: rgb(0, 0, 0);">
<br>
</div>
<div style="font-family: "Segoe UI", "Helvetica Neue", sans-serif; font-size: 9pt; color: rgb(0, 0, 0);">
I will take a look at the code tomorrow; my C isn't great but I think perhaps the answer is in the way the tags are applied. Annoyingly, the log clearly shows that the tag 'vms' is being set by the 'dhcp-mac' config variable, so it's obviously being picked
 up! </div>
<div style="font-family: "Segoe UI", "Helvetica Neue", sans-serif; font-size: 9pt; color: rgb(0, 0, 0);">
<br>
</div>
<div style="font-family: "Segoe UI", "Helvetica Neue", sans-serif; font-size: 9pt; color: rgb(0, 0, 0);">
Any more thoughts!?</div>
<div style="font-family: "Segoe UI", "Helvetica Neue", sans-serif; font-size: 9pt; color: rgb(0, 0, 0);">
<br>
</div>
<div style="font-family: "Segoe UI", "Helvetica Neue", sans-serif; font-size: 9pt; color: rgb(0, 0, 0);">
Many thanks in advance,</div>
<div style="font-family: "Segoe UI", "Helvetica Neue", sans-serif; font-size: 9pt; color: rgb(0, 0, 0);">
<br>
</div>
<div style="font-family: "Segoe UI", "Helvetica Neue", sans-serif; font-size: 9pt; color: rgb(0, 0, 0);">
Dave</div>
<div id="appendonsend"></div>
<hr style="display:inline-block;width:98%" tabindex="-1">
<div id="divRplyFwdMsg" dir="ltr"><font face="Calibri, sans-serif" style="font-size:11pt" color="#000000"><b>From:</b> Dnsmasq-discuss <dnsmasq-discuss-bounces@lists.thekelleys.org.uk> on behalf of Geert Stappers <stappers@stappers.nl><br>
<b>Sent:</b> 06 April 2019 02:28<br>
<b>To:</b> dnsmasq-discuss@lists.thekelleys.org.uk<br>
<b>Subject:</b> Re: [Dnsmasq-discuss] DHCP tag being ignored?</font>
<div> </div>
</div>
<div class="BodyFragment"><font size="2"><span style="font-size:11pt;">
<div class="PlainText">On Fri, Apr 05, 2019 at 09:43:12PM +0000, Dave Thompson wrote:<br>
> Hi there,<br>
> <br>
> I am trying to configure Dnsmasq to provide a custom range of IP<br>
> addresses for my VMs which will then map to a certain subdomain. The<br>
> trouble is, the tag is being found (I can see in the log file) but<br>
> the correct IP range is never provided.<br>
> <br>
> Here's my config file:<br>
> <br>
> domain=int.[redacted]<br>
> domain=vm.int.[redacted],192.168.1.50,192.168.1.150<br>
> <br>
> dhcp-range=192.168.0.50,192.168.0.150,12h<br>
> dhcp-range=tag:vms,192.168.1.50,192.168.1.150,12h<br>
<br>
So<br>
ccc.ddd.0.nnn and<br>
ccc.ddd.1.nnn<br>
 <br>
> dhcp-mac=set:vms,08:00:27:*:*:*<br>
> <br>
> dhcp-host=98:E7:F4:BA:3D:AA,192.168.0.80<br>
> dhcp-leasefile=/var/lib/misc/dnsmasq.leases<br>
> dhcp-authoritative<br>
> <br>
> log-dhcp<br>
> <br>
> >From the log:<br>
> <br>
> Apr  5 17:37:39 pi dnsmasq-dhcp[21541]: 3063663390 available DHCP range: 192.168.0.50 -- 192.168.0.150<br>
    missing the   192.168.1.50   --   192.168.1.150  range<br>
> Apr  5 17:37:39 pi dnsmasq-dhcp[21541]: 3063663390 vendor class: MSFT 5.0<br>
> Apr  5 17:37:39 pi dnsmasq-dhcp[21541]: 3063663390 client provides name: DWT-VPC-W7-0<br>
> Apr  5 17:37:39 pi dnsmasq-dhcp[21541]: 3063663390 DHCPINFORM(eth0) 192.168.0.104 08:00:27:ab:8b:7e<br>
    eth0   ccc.ddd.0.nnn   08:00:27:*:*:*<br>
> Apr  5 17:37:39 pi dnsmasq-dhcp[21541]: 3063663390 tags: vms, eth0<br>
> Apr  5 17:37:39 pi dnsmasq-dhcp[21541]: 3063663390 DHCPACK(eth0) 192.168.0.104 08:00:27:ab:8b:7e DWT-VPC-W7-0<br>
> <br>
> Can any of you point out what I am missing, please?<br>
<br>
Start with changing your<br>
} domain=int.[redacted]<br>
} domain=vm.int.[redacted],192.168.1.50,192.168.1.150<br>
} <br>
} dhcp-range=192.168.0.50,192.168.0.150,12h<br>
} dhcp-range=tag:vms,192.168.1.50,192.168.1.150,12h<br>
<br>
into<br>
<br>
 domain=int.[redacted]<br>
 domain=vm.int.[redacted],192.168.0.151,192.168.0.200<br>
 <br>
 dhcp-range=192.168.0.50,192.168.0.150,12h<br>
 dhcp-range=tag:vms,192.168.0.151,192.168.0.200,12h<br>
<br>
to get<br>
} Dnsmasq to provide a custom range of IP addresses<br>
} for VMs which will then map to a certain subdomain.<br>
 <br>
So all in  ccc.ddd.X.nnn<br>
<br>
<br>
Extending it to   ccc.ddd.A.nnn and  ccc.ddd.B.nnn will<br>
take extra effort.<br>
<br>
<br>
> Thank you very much,<br>
> <br>
> Dave<br>
<br>
<br>
Looking forward to the report of the success story.<br>
Yes, even little success stories are welcome.<br>
<br>
<br>
Groeten<br>
Geert Stappers<br>
-- <br>
Leven en laten leven<br>
<br>
_______________________________________________<br>
Dnsmasq-discuss mailing list<br>
Dnsmasq-discuss@lists.thekelleys.org.uk<br>
<a href="https://nam02.safelinks.protection.outlook.com/?url=http%3A%2F%2Flists.thekelleys.org.uk%2Fmailman%2Flistinfo%2Fdnsmasq-discuss&amp;data=02%7C01%7C%7Cdbd7864c35cf4644b59308d6ba5b486c%7C84df9e7fe9f640afb435aaaaaaaaaaaa%7C1%7C0%7C636901298550046672&amp;sdata=crJBCTi1xx%2BMOsOUAgsG%2B5Wt%2BRlA9uoqElFxUHWhsYA%3D&amp;reserved=0">https://nam02.safelinks.protection.outlook.com/?url=http%3A%2F%2Flists.thekelleys.org.uk%2Fmailman%2Flistinfo%2Fdnsmasq-discuss&amp;data=02%7C01%7C%7Cdbd7864c35cf4644b59308d6ba5b486c%7C84df9e7fe9f640afb435aaaaaaaaaaaa%7C1%7C0%7C636901298550046672&amp;sdata=crJBCTi1xx%2BMOsOUAgsG%2B5Wt%2BRlA9uoqElFxUHWhsYA%3D&amp;reserved=0</a><br>
</div>
</span></font></div>
</body>
</html>