How does DHCPD determine what IP address to assign and...

Ryan McCain Ryan.McCain at dss.state.la.us
Fri Dec 28 15:55:00 UTC 2007



>>> On Thu, Dec 27, 2007 at  5:54 PM, in message
<a06240800c399eb615c44 at simon.thehobsons.co.uk>, Simon Hobson
<dhcp1 at thehobsons.co.uk> wrote: 
> Ryan McCain wrote:
> 
>>Here is a snip from my leases file:
>>
>>lease 10.116.6.142 {
>>   starts 0 2007/11/11 01:44:43;
>>   ends 0 2007/11/11 01:45:02;
>>   tstp 0 2007/11/11 01:45:02;
>>   binding state free;
>>   hardware ethernet 00:10:7b:4d:73:c6;
>>   uid "\000cisco-10.116.6.251-Async17";
>>}
>>lease 10.116.6.179 {
>>   starts 1 2007/11/12 03:23:15;
>>   ends 2 2007/11/13 03:23:15;
>>   tstp 2 2007/11/13 03:23:15;
>>   binding state free;
>>   hardware ethernet 00:10:7b:4d:73:c6;
>>   uid "\000cisco-10.116.6.251-Async25";
>>
>>So, its  not always Async32, but it will always contain "-Async".
>>
>>If I understand you correctly the syntax would be:
>>
>>match if substring(option dhcp-client-identifier, 3,5) = "Async";
>>
>>Correct?
>>
>>I know the 3,5 are wrong based on the other post but as far as using 
>>the right option, dhcp-client-identifier is the correct one to use 
>>in this scenario?
> 
> Yes.


Am I getting warmer:

class "DialUp" {
    match if ( (substring(suffix(dhcp-client-identifier,7),0,5)="Async");
     or
     (substring(suffix(dhcp-client-identifier,6),0,5)="Async") );
       log (info, " Matched Dialup Rule");


--SNIP--

subnet 10.116.6.0 netmask 255.255.255.0 {
     pool {
         allow members of "DialUp";
         range 10.116.6.1 10.116.6.8;
         option routers 10.116.6.1;
         }

subnet 10.116.6.0 netmask 255.255.255.0 {
     pool {
         range 10.116.6.9 10.116.6.250;
         option routers 10.116.6.1;
         }


..My semicolons might be wrong or even how I start the match statement...?..

...I'd like to at least get someone from here to say "looks good" before I go ahead with the change.  I'd rather  not put in a change request, have the change not go through and re-schedule it 5-6 times until I get the syntax right.  Like I said previously, by powers out of my control we don't have a test environment for this so I appreciate you guys time.

Thanks,
Ryan



More information about the dhcp-users mailing list