Netgate Discussion Forum
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Search
    • Register
    • Login

    Kea DHCP stops working

    DHCP and DNS
    16
    61
    7.9k
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • M
      MacUsers
      last edited by

      slowly thinking again, it's actually happening for me from the day one. It was for a different reasone but I reported here too:

      https://forum.netgate.com/topic/196090/pfsense-behind-pfsense-not-getting-wan-ip-from-pfs1/7?_=1739914407057

      1 Reply Last reply Reply Quote 0
      • stephenw10S
        stephenw10 Netgate Administrator
        last edited by

        What I expect to happen here is the device keeps the dynamic IP lease until it tries to renew it.

        If you cleared the leases in pfSense such that Kea doesn't show it at all are you sure it is actually pulling a new lease at all?

        M 1 Reply Last reply Reply Quote 0
        • M
          MacUsers @stephenw10
          last edited by

          @stephenw10 I forced Renew DHC Lease on my MacBook after giving it a static-dhcp IP in PFS but it was still getting the old dynamic IP. But the strange thing is, that wasn't showing up under the Status >> DHCP Leases at all.

          I haven't seen this before and it is happening with even the old devices. I replaced by DIY box with 8200 and upgraded to v24.11 at the same time - all I can say, it started happening after one of the either.

          Just to give it a benefit of doubt: how do I chk that device was actually pulling a new lease?

          stephenw10S 1 Reply Last reply Reply Quote 0
          • M
            MacUsers
            last edited by

            okay, basically nothing is changng/updating related to DHCP. In one of the static-mappings, I provided custom DNS Servers (under the Server Options) and it's still showing the old DNS server address, even after restarting the client device. I'm very sure that it won't change, regardlessly what I do from/on the client side, nothing will change until I reboot the PFS box.

            I'll restart and report here back soon.

            GertjanG 1 Reply Last reply Reply Quote 0
            • stephenw10S
              stephenw10 Netgate Administrator @MacUsers
              last edited by

              @MacUsers said in Kea DHCP stops working:

              Just to give it a benefit of doubt: how do I chk that device was actually pulling a new lease?

              The logging in Kea is (currently) unhelpful for that.

              The only way to really know for sure would be to run a packet capture when the client renews and see what's actually being sent.

              1 Reply Last reply Reply Quote 0
              • GertjanG
                Gertjan @MacUsers
                last edited by

                @MacUsers

                The packet capture setup for DHCPv4 :

                e45887d8-12ea-477d-92c3-7ab0235b6e02-image.png

                1. Select the interface you want to capture, typically LAN

                2. The details : you want them all

                3. It's UDP

                4. and ports involved are 67 and 68.

                5. Hit start.

                6. Go to a device, and execute the DHCP Release and then DHCP renew command.

                Get back to pfSense, and you should see a (1) packets coming in (the DHCP request) and the one packet getting send to the device with the DHCP lease info.

                No "help me" PM's please. Use the forum, the community will thank you.
                Edit : and where are the logs ??

                1 Reply Last reply Reply Quote 2
                • M
                  MacUsers
                  last edited by MacUsers

                  Okay, I do see the request hitting PFS when I release and renew the lease:

                  91a765ef-d76d-4dc7-8224-528e42cd289a-image.png

                  But no change in IP at all, as it should be 10.1.20.12 now as that's what the static mapping is now set:
                  7ac88161-a076-4456-9750-fb1bf68c745e-image.png

                  This is happening for every single devices I have tested so far. Do you need the full capture?

                  1 Reply Last reply Reply Quote 0
                  • stephenw10S
                    stephenw10 Netgate Administrator
                    last edited by

                    Hmm, note that it's requesting the old IP. If you clear the client side lease cache does it get the new static IP?

                    Might need to force that in Kea. 🤔

                    M 2 Replies Last reply Reply Quote 0
                    • M
                      MacUsers @stephenw10
                      last edited by MacUsers

                      @stephenw10 I did everything: restarted Kea, cleared client side lease, even tried with a brand new device, predefined static mapping even before pluging in - not getting the actual IP if PFS not rebooted. Trying out all the usual stuff for almost a week now.
                      In case of the brand new device, it's getting an IP from the dynamic pool but that lease is not showing up in Status > DHCP lease at all.

                      1 Reply Last reply Reply Quote 0
                      • M
                        MacUsers @stephenw10
                        last edited by MacUsers

                        @stephenw10 said in Kea DHCP stops working:

                        note that it's requesting the old IP

                        Question though - how it's gonna know what IP to ask for, in the first place?
                        AFAIK, device broadcasts a DHCP Discover message to find a DHCP server and the DHCP server responds with a DHCP Offer giving it an IP. Kea should offer the IP from static-mapping and after accepting that offer (followed by a DHCP Request), it should be Acknowledged by the server - is not what happens?

                        1 Reply Last reply Reply Quote 0
                        • stephenw10S
                          stephenw10 Netgate Administrator
                          last edited by

                          Yes, but when it's renewing it will just request the old IP. And in some cases will just request an old cached lease address anyway. The server can refuse and issue a new lease.

                          However it sounds like it's just not seeing the new static lease entry.
                          Do you see the reservation listed in /usr/local/etc/kea/kea-dhcp4.conf?

                          M 1 Reply Last reply Reply Quote 0
                          • M
                            MacUsers @stephenw10
                            last edited by

                            @stephenw10 said in Kea DHCP stops working:

                            Do you see the reservation listed in /usr/local/etc/kea/kea-dhcp4.conf?

                            Yes, the IP is in the file against the correct MAC
                            cac71585-8909-462d-bdbc-dce1f6d2e4b1-image.png

                            but looks like not being offered?

                            1 Reply Last reply Reply Quote 0
                            • M
                              MacUsers
                              last edited by MacUsers

                              @RobbieTT said in KEA DHCP - lacking features:

                              @maverickws

                              Before it went live it was suggested that encouraging users to leave ISC for Kea was rather over done, considering its immaturity.

                              I did switch to Kea during the beta period and it was seamless with no apparent drawbacks but once I released some basics were missing and that it was relying on previous ISC managed data to function, had me switching back.

                              As I understand it, simple static mappings / reservations from Kea are not actually supported. However, it may give an illusion of functionality if you have run ISC previously. Existing mappings / reservations will still be resolvable as the hosts file still contains them as a hang-over from running ISC. Any new mappings added or modified will not be resolvable.

                              To me, the ability to set a static mapping / reservation is a basic cornerstone of networking. I think there will be a cascade of confusion as and when the previous hosts file becomes out-of-date.

                              ☕️

                              That's a post from back in 2023 and looks like it's not fixed. I think that's exactly happening here too - the already existing records (from ISC) are working and the new ones are not at all.

                              1 Reply Last reply Reply Quote 0
                              • stephenw10S
                                stephenw10 Netgate Administrator
                                last edited by

                                Nope that's unrelated. At that time both dynamic and static leases were not resolvable at all. 24.11 has out custom binary that handles the Kea-Unbound glue to allow it. But that didn't affect the actual leases, only resolving hosts.

                                What client type are you testing this from?

                                M 1 Reply Last reply Reply Quote 0
                                • M
                                  MacUsers @stephenw10
                                  last edited by

                                  @stephenw10 said in Kea DHCP stops working:

                                  Nope that's unrelated. At that time both dynamic and static leases were not resolvable at all.

                                  May be it was but still matches exactly with my case. Probably this particular part somehow escape testing before release?

                                  @stephenw10 said in Kea DHCP stops working:

                                  What client type are you testing this from?

                                  I tested with two MacBooks, Minix U22-XJ, Raspberry Pi 5 and even with a Netgate 6200 - none of 'em got the IP they deserv :)
                                  If that's what you meant. It doesn't matter what client or type - any new mapping (brand-new or edited) not working.

                                  Pls let me know if there is anything else I can provide to get it fix.

                                  stephenw10S 1 Reply Last reply Reply Quote 0
                                  • stephenw10S
                                    stephenw10 Netgate Administrator @MacUsers
                                    last edited by

                                    @MacUsers said in Kea DHCP stops working:

                                    May be it was but still matches exactly with my case.

                                    So you are also seeing issues resolving hosts?

                                    M 1 Reply Last reply Reply Quote 0
                                    • stephenw10S
                                      stephenw10 Netgate Administrator
                                      last edited by

                                      Can you test the 25.03-Beta?
                                      I can't replicate that issue here. I reconnect a client (Linux Laptop) after setting a static lease and it immediately pulls that.

                                      M 1 Reply Last reply Reply Quote 0
                                      • M
                                        MacUsers @stephenw10
                                        last edited by

                                        @stephenw10 said in Kea DHCP stops working:

                                        So you are also seeing issues resolving hosts?

                                        I was talking about this part:
                                        84a75a99-3826-4a53-a954-f8aba8f772f1-image.png

                                        1 Reply Last reply Reply Quote 0
                                        • M
                                          MacUsers @stephenw10
                                          last edited by

                                          @stephenw10 said in Kea DHCP stops working:

                                          Can you test the 25.03-Beta?

                                          Is Beta stable enough to run for regulat use atm? Anything in particular I should be aware of before upgrading?

                                          -S

                                          1 Reply Last reply Reply Quote 0
                                          • stephenw10S
                                            stephenw10 Netgate Administrator
                                            last edited by

                                            Yes, I'm running it as my edge device now and have been for some time.

                                            If you're running ZFS you always roll back to the 24.11 BE snap anyway.

                                            M 1 Reply Last reply Reply Quote 0
                                            • First post
                                              Last post
                                            Copyright 2025 Rubicon Communications LLC (Netgate). All rights reserved.