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

    DHCP not working / self-assigned IP address

    Scheduled Pinned Locked Moved DHCP and DNS
    43 Posts 3 Posters 47.5k Views
    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.
    • jimpJ
      jimp Rebel Alliance Developer Netgate
      last edited by

      I restored the configurations you sent me onto a pair of VMs and my DHCP worked OK. I pulled an IP, and the status was normal. So it's not making a whole lot of sense why it isn't working for you as-is. I still have a couple more things to test though.

      What kind of a switch do you have on LAN? Was anything else plugged into it besides the netgate boxes and your laptop?

      Remember: Upvote with the 👍 button for any user/post you find to be helpful, informative, or deserving of recognition!

      Need help fast? Netgate Global Support!

      Do not Chat/PM for help!

      1 Reply Last reply Reply Quote 0
      • S
        scar
        last edited by

        @jimp:

        What kind of a switch do you have on LAN? Was anything else plugged into it besides the netgate boxes and your laptop?

        The switch is a Cisco SGE2000.  Two other servers and their LOM interfaces are plugged into the switch…. so, 7 ports are being used on the switch if you count my laptop.

        1 Reply Last reply Reply Quote 0
        • jimpJ
          jimp Rebel Alliance Developer Netgate
          last edited by

          I just made a VM CARP pair with NanoBSD images and restored your configuration there and it also worked. (My previous test was with full install VMs)

          Is there something on the switch that might be impairing DHCP? Can you try a cheap "dumb" switch (non-managed) temporarily to see if it behaves differently? The servers aren't trying to also be DHCP servers, are they?

          In every case I tried, I was able to pull an IP, and when I checked the DHCP leases, the failover status on both was "normal".

          Remember: Upvote with the 👍 button for any user/post you find to be helpful, informative, or deserving of recognition!

          Need help fast? Netgate Global Support!

          Do not Chat/PM for help!

          1 Reply Last reply Reply Quote 0
          • S
            scar
            last edited by

            @jimp:

            Is there something on the switch that might be impairing DHCP?

            i have no idea ;)  because of this DHCP issue, i haven't been able to log into the switch to see.  i've never used a cisco managed switch before, anyway… is there anything in particular i should look for in its configuration that might be causing problems?

            Can you try a cheap "dumb" switch (non-managed) temporarily to see if it behaves differently?

            yes, i'll give it a shot.

            The servers aren't trying to also be DHCP servers, are they?

            no

            1 Reply Last reply Reply Quote 0
            • jimpJ
              jimp Rebel Alliance Developer Netgate
              last edited by

              Not sure exactly what it might be in the switch config, but testing against a small unmanaged switch would let us know if that's even the right direction to be looking.

              Remember: Upvote with the 👍 button for any user/post you find to be helpful, informative, or deserving of recognition!

              Need help fast? Netgate Global Support!

              Do not Chat/PM for help!

              1 Reply Last reply Reply Quote 0
              • jimpJ
                jimp Rebel Alliance Developer Netgate
                last edited by

                Also, the contents of the DHCP log from master and slave will help. Status > System Logs, DHCP tab.

                Remember: Upvote with the 👍 button for any user/post you find to be helpful, informative, or deserving of recognition!

                Need help fast? Netgate Global Support!

                Do not Chat/PM for help!

                1 Reply Last reply Reply Quote 0
                • S
                  scar
                  last edited by

                  i tried with an ASUS GX-D1081… no such luck.  and, there is absolutely nothing in the DHCP logs.

                  1 Reply Last reply Reply Quote 0
                  • jimpJ
                    jimp Rebel Alliance Developer Netgate
                    last edited by

                    Very odd that it is completely blank in the logs. Usually there is at least a startup message.

                    Not sure how much trouble it would be, but is there any way you can reimage those CF cards with a stock pfSense 1.2.3 image and restore your config? I wonder if it might be something specific to the Netgate images that were preloaded.

                    Remember: Upvote with the 👍 button for any user/post you find to be helpful, informative, or deserving of recognition!

                    Need help fast? Netgate Global Support!

                    Do not Chat/PM for help!

                    1 Reply Last reply Reply Quote 0
                    • S
                      scar
                      last edited by

                      :\  That is a lot of trouble for me, unless there is a step by step guide available.

                      1 Reply Last reply Reply Quote 0
                      • jimpJ
                        jimp Rebel Alliance Developer Netgate
                        last edited by

                        Not really that difficult, just time consuming really, and requires a box with a CF reader.

                        I've got copies of the Netgate images here somewhere, I'll see if I can image them to a VM and try that instead.

                        Remember: Upvote with the 👍 button for any user/post you find to be helpful, informative, or deserving of recognition!

                        Need help fast? Netgate Global Support!

                        Do not Chat/PM for help!

                        1 Reply Last reply Reply Quote 0
                        • jimpJ
                          jimp Rebel Alliance Developer Netgate
                          last edited by

                          Good news, and bad news.

                          Good news is I finally reproduced it and have a fix. The bad news it that it is specific to your configuration :-)

                          When you are using routers in a CARP pair, you can't use Proxy ARP VIPs. These were syncing into the backup config as empty <vip>tags, which was tricking the DHCP server there into thinking it should be primary.

                          So DHCP didn't work because they both thought they were primary.

                          The fix could either be to switch to 'other' type VIPs, and define them on both master and backup, or switch them to CARP if you can. Proxy ARP can't work on both routers in a failover configuration.

                          The other fix – if you really need proxy arp on the main unit -- is to patch services.inc to handle the empty tags better. I have a patch if you need it.</vip>

                          Remember: Upvote with the 👍 button for any user/post you find to be helpful, informative, or deserving of recognition!

                          Need help fast? Netgate Global Support!

                          Do not Chat/PM for help!

                          1 Reply Last reply Reply Quote 0
                          • S
                            scar
                            last edited by

                            Thank you for discovering this.  Seems like a bug to me.  Is this only for the Netgate installation, or does it happen with a standard installation also?

                            i don't know if can use the type "Other" VIP.  i have these public IP addresses which will be tied to various hostnames.  the public IP address will need to be mapped to various internal IP addresses, depending on what service is accessed.  will "Other" VIP's function this way?

                            1 Reply Last reply Reply Quote 0
                            • jimpJ
                              jimp Rebel Alliance Developer Netgate
                              last edited by

                              It happened with the normal images as well once I looked deeper. I don't know why it was OK when I first restored your configuration, but it's possible that dhcpd hadn't reloaded after the empty tags sync'd over.

                              If your other IPs are in the same subnet as WAN, use CARP. If you have another subnet of IPs and those IPs are routed to your WAN IP, an 'other' type will work.

                              Using proxy arp IPs with CARP isn't considered a valid configuration, which is why nobody else seems to have hit this.

                              Remember: Upvote with the 👍 button for any user/post you find to be helpful, informative, or deserving of recognition!

                              Need help fast? Netgate Global Support!

                              Do not Chat/PM for help!

                              1 Reply Last reply Reply Quote 0
                              • S
                                scar
                                last edited by

                                ok… i will try changing them all to CARP VIPs tonight, if possible, and let you know how it fares.

                                1 Reply Last reply Reply Quote 0
                                • S
                                  scar
                                  last edited by

                                  i changed them all to CARP VIPs but, still no luck.  i put each address into it's own VHID group number but i used the same password for all of them… the password doesn't seem to matter anyway.  on 'status -> dhcp leases' the state is still "recover".  i notice that if i go to 'status -> CARP', the status for all of the public VIPs is "MASTER" on both the master and backup firewalls.  i'm sorry i obviously don't know what i'm doing ;)  but i'll learn in time.  i'll send ya my current configs.  is there any way i make the firewall config accessible from outside the datacenter?  then i don't keep having to make trips back and forth each time....

                                  1 Reply Last reply Reply Quote 0
                                  • jimpJ
                                    jimp Rebel Alliance Developer Netgate
                                    last edited by

                                    I restored the new configuration files you sent, and all of the CARP IPs show up properly; master on master, and backup on backup. The DHCP daemon came up properly this time too, in a normal state on both sides.

                                    However, I did notice that the WAN IP is set to the same IP address on both of them (x.x.x.16) when it should be different on each box (if you want to use .16 as the shared IP, it must also be a CARP IP), and also the subnet mask of all those CARP IPs should be /28, not /32.

                                    Remember: Upvote with the 👍 button for any user/post you find to be helpful, informative, or deserving of recognition!

                                    Need help fast? Netgate Global Support!

                                    Do not Chat/PM for help!

                                    1 Reply Last reply Reply Quote 0
                                    • S
                                      scar
                                      last edited by

                                      i don't get why the config works for you but not for me…  i even tried rebooting the two boxes and still everything shows up as MASTER.  maybe i'll ask the datacenter support staff to look at it.

                                      1 Reply Last reply Reply Quote 0
                                      • jimpJ
                                        jimp Rebel Alliance Developer Netgate
                                        last edited by

                                        When you tried that unmanaged switch, did you try it on the WAN, the LAN, or both? CARP relies on broadcasts (as does DHCP) so if their switches are blocking anything like that it can be an issue.

                                        If your WANs are on your ISP's switch/network and not in its own VLAN, it's also possible your VHIDs might be conflicting or they may be blocking some broadcast traffic there.

                                        As for accessing the router remotely, it should be as easy as (a) switching the webgui to use HTTPS under system > general (for security reasons), and (b) adding a firewall rule on WAN that allows TCP traffic in to the destination of "WAN Address" on port 443 (pick https from the list or type in 443). Then you should be able to access the WebGUI from anywhere.

                                        Moving it to another port (and using that port in the rule) would be even better, something like 4433, 44433, etc. A VPN would be ideal but is much harder to setup.

                                        Remember: Upvote with the 👍 button for any user/post you find to be helpful, informative, or deserving of recognition!

                                        Need help fast? Netgate Global Support!

                                        Do not Chat/PM for help!

                                        1 Reply Last reply Reply Quote 0
                                        • S
                                          scar
                                          last edited by

                                          Thanks for the info.  I'll talk to the ISP about it.  I am planning on setting up a VPN in the future.

                                          1 Reply Last reply Reply Quote 0
                                          • S
                                            scar
                                            last edited by

                                            my ISP asked me to reiterate that i am only using one uplink, i.e. only the WAN port on the master is plugged in.  is that having an adverse effect on the setup?

                                            secondly, they told me they use HSRP to provide redundant gateways and want to know: is it possible to allow traffic to pass between both WAN ports (possibly using the sync port) without being molested?

                                            thanks

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