LAN DHCPv4 server buggy IP assignments

Started by ruuskil, November 19, 2021, 08:32:17 PM

Previous topic - Next topic
I have several LAN clients, some are configured with static IP address from DHCP server and some are dynamic addresses. Problem is that sometimes when I add a new client to my network, it gets assigned a same IP address which is supposed to be reserved for a static client.

Workaround for this is to manually configure the DHCP server to assign a free static IP to the new client. This resolves the conflict but is extra work. I've never seen any of my previous gateways to assign conflicting addresses. Is this a bug or have I missed something with my dhcp configuration?

The only thing that occurs - might your DHCP reservations overlap your DHCP pool range? I am running OPNsense 21.7.5 at home, using the DHCPv4 service and the Unbound DNS service. The [LAN] DHCPv4 service is configured as follows:

Subnet: 192.168.124.0/24  |  Available Range: 192.168.124.1 - 192.168.124.254
Range: 192.168.124.100 - 192.168.124.149 <-- Pool of addresses to be assigned dynamically
DNS Server: 192.168.124.1  |  Gateway: 192.168.124.1
Reservations:
192.168.124.50, 192.168.124.52, 192.168.124.54, 192.168.124.56, 192.168.124.58, 192.168.124.60

There are usually about 15 - 20 hosts active at any given time, including the 6 reservations. This basic setup has been running for a couple of years and I've never had any trouble with it.

Hope this helps - good luck.

Static assignments and the dynamic range for a given subnet may indeed not overlap.
Deciso DEC750
People who think they know everything are a great annoyance to those of us who do. (Isaac Asimov)

If I'm not mistaken, this is due to the way OPNsense builds the dhcpd configuration file.  :o

More info here, and likely other places too.  ::)

Thanks everyone. I need to take a look at my dynamic vs static pools and change config so that they don't overlap. It seems that I'm not the only one who is confused by this behavior.

I've had many firewalls/gateways over the years including sophos, ubiquiti and a handful of zyxels and all of them assign a static IP address only to a client that is supposed to receive that particular IP.

OK so I configured my pool range 192.168.1.10 - 192.168.1.100 and all static addresses I assign between 192.168.1.101 - 192.168.1.254

So far everything seems to work like it should.