You can however implement allow/deny statements within your subnet declaration specifying the class you wish to allow/deny<br><br><div class="gmail_quote">On Fri, Jun 1, 2012 at 5:44 AM, Randall C Grimshaw <span dir="ltr"><<a href="mailto:rgrimsha@syr.edu" target="_blank">rgrimsha@syr.edu</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">




<div bgcolor="#ffffff">
<div style="direction:ltr;font-size:10pt;font-family:Tahoma">
<p>not a bug, but perhaps a misunderstanding of the parser.</p>
<p>you must keep the class definitions out of the subnets definitions.</p>
<p>for the parser there is no relationship so you have effectively created a duplication</p>
<p>which results in a collision.</p>
<div>
<p> </p>
<div><font face="Tahoma">Randall Grimshaw <a href="mailto:rgrimsha@syr.edu" target="_blank">
rgrimsha@syr.edu</a></font></div>
<div> </div>
</div>
<div style="font-size:16px;font-family:Times New Roman">
<hr>
<div style="DIRECTION:ltr"><font color="#000000" face="Tahoma"><b>From:</b> dhcp-users-bounces+rgrimsha=<a href="mailto:syr.edu@lists.isc.org" target="_blank">syr.edu@lists.isc.org</a> [dhcp-users-bounces+rgrimsha=<a href="mailto:syr.edu@lists.isc.org" target="_blank">syr.edu@lists.isc.org</a>] on behalf of Nuno Marques [<a href="mailto:nmm@ul.pt" target="_blank">nmm@ul.pt</a>]<br>

<b>Sent:</b> Friday, June 01, 2012 7:28 AM<br>
<b>To:</b> Users of ISC DHCP<br>
<b>Subject:</b> Wrong gateway when using class in a subnet<br>
</font><br>
</div>
<div></div>
<div>Hi all,<br>
<br>
I'm using dhcp-4.1.1-25.P1.el6_2.1.i686 on RHEL6, and have somthing like this:<br>
<br>
subnet 10.99.112.0 netmask 255.255.255.0{<br>
                option routers 10.99.112.1;<br>
<br>
        class "Cisco-AP-c1140" {<br>
        match if option vendor-class-identifier = "Cisco AP c1140";<br>
        option vendor-class-identifier "Cisco AP c1140";<br>
        vendor-option-space Cisco_LWAPP_AP;<br>
        option Cisco_LWAPP_AP.server-address 10.99.4.221; }<br>
<br>
....<br>
}<br>
<br>
subnet 10.99.113.0 netmask 255.255.255.0{<br>
                option routers 10.99.113.1;<br>
<br>
        class "Cisco-AP-c1140" {<br>
        match if option vendor-class-identifier = "Cisco AP c1140";<br>
        option vendor-class-identifier "Cisco AP c1140";<br>
        vendor-option-space Cisco_LWAPP_AP;<br>
        option Cisco_LWAPP_AP.server-address 10.99.4.221; }<br>
<br>
....<br>
}<br>
<br>
The problem is, an AP on the second subnet will receive the gateway from the first (10.99.112.1).
<br>
My guess is DHCP is giving the first 'option router' that matches the class.<br>
<br>
If I put the class declaration on the top of the configuration and remove it from every subnet it works as expected, but I got several subnets that shouldn't have this configuration, so I want to keep it out of the general configuration.<br>

<br>
Is this a bug?<br>
<br>
Thanks,<br>
<br>
<div>-- <br>
<font color="#000000"><b><font face="Times New Roman, serif">Nuno Miguel Lopes Marques</font></b></font><br>
<div>
<div><font face="Calibri, sans-serif">
<div><font size="3"><font face="Times New Roman, serif"><b></b></font></font><font color="#000000" face="Calibri, sans-serif"><font size="3"><font>Núcleo de Administração de Sistemas</font></font></font><font color="#000000" size="3"><font>
 -  </font><font>Área de Sistemas e Comunicações</font><font> - Serviços Tecnológicos</font></font></div>
<font color="#000000"></font>
<div> </div>
<font color="#000000"></font>
<div style="MARGIN-TOP:4pt"><font color="#000000"><b>E.</b> <a href="mailto:nmm@ul.pt" target="_blank">
nmm@ul.pt</a>  </font></div>
<font color="#000000"></font>
<div style="MARGIN-TOP:4pt"><font color="#000000"><b>T.</b> <a href="tel:%2B351%2021%20044%2034%2023" value="+351210443423" target="_blank">+351 21 044 34 23</a> -
<b>Ext.</b> 30243</font></div>
<font color="#000000"></font>
<div style="MARGIN-TOP:4pt"><font color="#000000"><b>M.</b> 924 138 406</font></div>
<font color="#000000"></font>
<div style="MARGIN-TOP:4pt"><font color="#000000"><b>Morada</b></font></div>
<font color="#000000"></font>
<div style="MARGIN-TOP:4pt"><font color="#000000">Alameda da Universidade, Cidade Universitária</font></div>
<font color="#000000"></font>
<div style="MARGIN-TOP:4pt"><font><font color="#000000">1649-004 Lisboa</font><br>
</font></div>
<font color="#000000"></font>
<div style="MARGIN-TOP:4pt"><font><br>
<b><a href="http://www.sp.ul.pt/" target="_blank">www.sp.ul.pt</a></b></font></div>
<div style="MARGIN-TOP:4pt"> </div>
<div style="MARGIN-TOP:4pt"><img src="cid:part3.03090109.04030302@ul.pt"><font><b>
</b></font></div>
<div> </div>
<div> </div>
<div> </div>
</font></div>
</div>
</div>
</div>
</div>
</div>
</div>

<br>_______________________________________________<br>
dhcp-users mailing list<br>
<a href="mailto:dhcp-users@lists.isc.org">dhcp-users@lists.isc.org</a><br>
<a href="https://lists.isc.org/mailman/listinfo/dhcp-users" target="_blank">https://lists.isc.org/mailman/listinfo/dhcp-users</a><br></blockquote></div><br><br clear="all"><br>-- <br>Jason Gerfen<br><a href="mailto:jason.gerfen@gmail.com" target="_blank">jason.gerfen@gmail.com</a><br>
<br><a href="http://www.github.com/jas-" target="_blank">http://www.github.com/jas-</a><br><a href="http://phpdhcpadmin.sourceforge.net" target="_blank">http://phpdhcpadmin.sourceforge.net</a><br><br>