Send dhcp-users mailing list submissions to
        dhcp-users@lists.isc.org

To subscribe or unsubscribe via the World Wide Web, visit
        https://lists.isc.org/mailman/listinfo/dhcp-users
or, via email, send a message with subject or body 'help' to
        dhcp-users-requ...@lists.isc.org

You can reach the person managing the list at
        dhcp-users-ow...@lists.isc.org

When replying, please edit your Subject line so it is more specific
than "Re: Contents of dhcp-users digest..."


Today's Topics:

   1. Re: Primary / Secundary cluster with synced leases created
      using omapi (Matt .)
   2. Re: Primary / Secundary cluster with synced leases created
      using omapi (Niall O'Reilly)
   3. Re: Primary / Secundary cluster with synced leases created
      using omapi (Shawn Routhier)
   4. Re: Primary / Secundary cluster with synced leases created
      using omapi (Matt .)
   5. Re: Primary / Secundary cluster with synced leases created
      using omapi (Simon Hobson)


----------------------------------------------------------------------

Message: 1
Date: Sat, 6 Aug 2016 22:48:35 +0200
From: "Matt ." <yamakasi....@gmail.com>
To: Users of ISC DHCP <dhcp-users@lists.isc.org>
Subject: Re: Primary / Secundary cluster with synced leases created
        using omapi
Message-ID:
        <CAPNQp067nTYf=n_52=qn=s7mvx7pemlk+zje04yckodsk3y...@mail.gmail.com>
Content-Type: text/plain; charset=UTF-8

OK, thanks for that information, that helps.

I have both of my dhcp servers as DHCP-helper in my switches so that
should normally work the way it should.

I need to higher up my logs to see what happens in syncing and will update here.

2016-08-06 22:43 GMT+02:00 S Carr <sjc...@gmail.com>:
> On 6 August 2016 at 21:29, Matt . <yamakasi....@gmail.com> wrote:
>> What you say happens, but when I reboot a machine with the secondary
>> dhcp server available only it doesn't get the same IP as it did before
>> failover....
>>
>> You say I should see a refresh of all IP's/Mac as they were assigned
>> on the primary ? I need to check but I don't see that  think.
>
> Primary should be syncing the leases to the secondary (and vice-versa)
> so both peers have the same MAC to IP mapping for the client. Normally
> DHCPD doesn't purge/reuse IP addresses until it needs to, so as long
> as you have sufficient IP addresses in the subnet then the client
> should get the same IP it had previously.
>
> If it's not then either your client is changing it's MAC address or
> something else is causing DHCPD to reuse the lease once the client
> releases it on shutdown, so it's not available when it comes back
> online.
> _______________________________________________
> dhcp-users mailing list
> dhcp-users@lists.isc.org
> https://lists.isc.org/mailman/listinfo/dhcp-users


------------------------------

Message: 2
Date: Sat, 06 Aug 2016 22:19:17 +0100
From: "Niall O'Reilly" <niall.orei...@ucd.ie>
To: "Users of ISC DHCP" <dhcp-users@lists.isc.org>
Subject: Re: Primary / Secundary cluster with synced leases created
        using omapi
Message-ID: <0dcae8fb-070c-4aad-95af-9255aef2f...@ucd.ie>
Content-Type: text/plain; format=flowed

On 6 Aug 2016, at 21:05, S Carr wrote:

> On 6 August 2016 at 20:51, Matt . <yamakasi....@gmail.com> wrote:
>> I was thinking about syncing the leases file but this might be not a 
>> good idea.
>>
>> Is it possible what I try to do ?
>
> Use DHCP Failover
> https://kb.isc.org/article/AA-00502/0/A-Basic-Guide-to-Configuring-DHCP-Failover.html

   Failover supports synchronization of pools of dynamically-assigned IP 
addresses.
   Static leases don't (or didn't use to) belong in pools.

   OP will need to add each new static lease on both servers, either in 
config or
   by parallel OMAPI updates.

   I hope this helps.

   Niall O'Reilly


------------------------------

Message: 3
Date: Sat, 6 Aug 2016 14:20:53 -0700
From: Shawn Routhier <s...@isc.org>
To: Users of ISC DHCP <dhcp-users@lists.isc.org>
Subject: Re: Primary / Secundary cluster with synced leases created
        using omapi
Message-ID: <c1489490-1966-4de4-ac85-ea4073c2d...@isc.org>
Content-Type: text/plain; charset=utf-8


> On Aug 6, 2016, at 1:43 PM, S Carr <sjc...@gmail.com> wrote:
> 
> On 6 August 2016 at 21:29, Matt . <yamakasi....@gmail.com> wrote:
>> What you say happens, but when I reboot a machine with the secondary
>> dhcp server available only it doesn't get the same IP as it did before
>> failover....
>> 
>> You say I should see a refresh of all IP's/Mac as they were assigned
>> on the primary ? I need to check but I don't see that  think.
> 
> Primary should be syncing the leases to the secondary (and vice-versa)
> so both peers have the same MAC to IP mapping for the client. Normally
> DHCPD doesn't purge/reuse IP addresses until it needs to, so as long
> as you have sufficient IP addresses in the subnet then the client
> should get the same IP it had previously.

It is true that the servers don?t purge leases in general.
But if the lease is allowed to expire it will go to either
free (on the primary) or backup (on the secondary).

If the server that owns that address is unavailable then
when the other server provides an address the client
won?t be able to get the original address.
> 
> If it's not then either your client is changing it's MAC address or
> something else is causing DHCPD to reuse the lease once the client
> releases it on shutdown, so it's not available when it comes back
> online.

> _______________________________________________
> dhcp-users mailing list
> dhcp-users@lists.isc.org
> https://lists.isc.org/mailman/listinfo/dhcp-users

shawn

------------------------------

Message: 4
Date: Sun, 7 Aug 2016 01:29:07 +0200
From: "Matt ." <yamakasi....@gmail.com>
To: Users of ISC DHCP <dhcp-users@lists.isc.org>
Subject: Re: Primary / Secundary cluster with synced leases created
        using omapi
Message-ID:
        <capnqp07nutgualkvqwaeagn_y_b+ljvszogz6ufxej0g+cg...@mail.gmail.com>
Content-Type: text/plain; charset=UTF-8

Nail; This helps a lot in clearification. Shawn the same for you.

The issue is that the dynamic leases with hostname and such on the
primary are not seen on the secondary in the leases file. I would
say... somewhere had to be that information like the same ? I only see
"free" ones on the secondary where a test client which has a dynamic
entry on the master is "free" without any further information (so
hostname) on the secondary.

So that is where my lease goes wrong when I turn off the primary,
reboot the client and the secondary hands out... it just picks an
available IP from the pool/range.

2016-08-06 23:20 GMT+02:00 Shawn Routhier <s...@isc.org>:
>
>> On Aug 6, 2016, at 1:43 PM, S Carr <sjc...@gmail.com> wrote:
>>
>> On 6 August 2016 at 21:29, Matt . <yamakasi....@gmail.com> wrote:
>>> What you say happens, but when I reboot a machine with the secondary
>>> dhcp server available only it doesn't get the same IP as it did before
>>> failover....
>>>
>>> You say I should see a refresh of all IP's/Mac as they were assigned
>>> on the primary ? I need to check but I don't see that  think.
>>
>> Primary should be syncing the leases to the secondary (and vice-versa)
>> so both peers have the same MAC to IP mapping for the client. Normally
>> DHCPD doesn't purge/reuse IP addresses until it needs to, so as long
>> as you have sufficient IP addresses in the subnet then the client
>> should get the same IP it had previously.
>
> It is true that the servers don?t purge leases in general.
> But if the lease is allowed to expire it will go to either
> free (on the primary) or backup (on the secondary).
>
> If the server that owns that address is unavailable then
> when the other server provides an address the client
> won?t be able to get the original address.
>>
>> If it's not then either your client is changing it's MAC address or
>> something else is causing DHCPD to reuse the lease once the client
>> releases it on shutdown, so it's not available when it comes back
>> online.
>
>> _______________________________________________
>> dhcp-users mailing list
>> dhcp-users@lists.isc.org
>> https://lists.isc.org/mailman/listinfo/dhcp-users
>
> shawn
> _______________________________________________
> dhcp-users mailing list
> dhcp-users@lists.isc.org
> https://lists.isc.org/mailman/listinfo/dhcp-users


------------------------------

Message: 5
Date: Sun, 7 Aug 2016 12:44:02 +0100
From: Simon Hobson <dh...@thehobsons.co.uk>
To: Users of ISC DHCP <dhcp-users@lists.isc.org>
Subject: Re: Primary / Secundary cluster with synced leases created
        using omapi
Message-ID: <1f55f691-d88e-4aba-8aeb-1b5508426...@thehobsons.co.uk>
Content-Type: text/plain; charset=us-ascii

Matt . <yamakasi....@gmail.com> wrote:

> I'm having an issue with a setup where I can't set static leases.

Define what you mean by static leases.

Do you mean a host statement with a "fixed address" statement, or a lease with 
the reserved flag set ?

I assume you mean the former, and that means that what you are setting isn't a 
"lease" in the conventional sense - host statements with fixed address do not 
create a lease through the normal lifetime. Normally these do not appear in the 
leases file at all, and I suspect that they do not get processed by failover 
either.
I'm assuming that they appear in the leases file when created via OMAPI as 
otherwise there would be no persistent storage of them.

So in this case, you need to apply the change to both servers.

Or, use reserved leases and failover which should work.

BTW - syncing the leases file is "fraught with difficulties" and is guaranteed 
to break things unless you use nothing but these static leases. The server you 
sync the file *to* will ignore it unless you stop the dhcpd service, swap out 
the file, and start the dhcpd service. This is because the leases file is 
"write only" - it is read once at service startup, and then it is only written 
(so there's persistent storage) - all the working data is held in ram.



------------------------------

Subject: Digest Footer

_______________________________________________
dhcp-users mailing list
dhcp-users@lists.isc.org
https://lists.isc.org/mailman/listinfo/dhcp-users

------------------------------

End of dhcp-users Digest, Vol 94, Issue 3
*****************************************

Reply via email to