pfsense DHCP Reservation Questions
-
@djtech2k not sure what part did not click for you.. You can not set a reservation for an IP inside your pool
If you have .10-.15 in you pool gets .12 - you can't then set a reservation -- 12 is inside the pool..
If you want 12 to be excluded for the pool then create a pool .10-.11 and another pool .13-15
-
@djtech2k said in pfsense DHCP Reservation Questions:
don't really understand why DHCP is doing what its doing on pfsense
See:
https://docs.netgate.com/pfsense/en/latest/services/dhcp/mappings-in-pools.html -
Yeah, I got it. I went back and looked over the dhcp config again to refresh my memory. I understand how they made reservations and scope work. I do not like how it works and I wish it were different, but it is what it is.
I wasnāt sure if there were any other options for dhcp of if I overlooked something or not. Sounds/looks there is not. So itāll have to be multiple smaller scopes that donāt include static/reservations or rearrange ip assignments on the network to accommodate a contiguous scope.
Validating is half the battle.
-
@djtech2k what I do when I add a new device is just let it get dhcp - then set a reservation for outside the pool. I'm not sure why anyone set a static on a device other than devices that don't even support dhcp
You can change its ip without ever having to touch it, you could even change whole network ip space. You can change options again without having to touch it..
My dhcp scopes are small .100-120 for example - rest of the space I just use as reservation. And its easy enough to know what IP is next to use..
-
@johnpoz said in pfsense DHCP Reservation Questions:
I'm not sure why anyone set a static on a device other than devices that don't even support dhcp
Because it prevent the most important infrastructure devices in the network to remain on their well-known IPs and not resort to APIPA should the non-redundant DHCP-service fail.
-
@P3R said in pfsense DHCP Reservation Questions:
Because it prevent the most important infrastructure devices in the network to remain on their well-known IPs
That's why static MAC DHCP lease were invented. Also valid for DHCPv6 btw.
Every device on my main LAN network support DHCPv4/DHCPv6.
Every device on my main LAN network always has the same IPv4/IPv6..
I've started to add a static MAC DHCP lease for every device I had back then (many decades ago), and continued to so for every new device I add (one or two every year).This means that I don't need to change something on the device, they are all 'out of the box', and these are printers, NAS, APs, PC's and servers, some witches, and some other 'special' stuff. 50 or so.
I've lost some what the notion of 'what IPv4 is sud by what device' as I gave them all my defined short host names.
Most devices don't even really use IPv4 anymore, they use IPv6 these days. And I'm not going to remember these anyway, they are to long, even when using 'short' mode.
I've my short host names, I will not break DNS, so everything works fine.If you don't have 24.11 with kea that supports this, stay with ISC and you're fine. Worked for me for since early 2010. ISC still rocks for billions of devices.
With 24.11 and kea, static DHCP work fine also.
Same thing for DHCPv6. -
@P3R where did you quote that from ;)
You know what needs static - loopback on your infrastructure equipment. The dhcp server ;) Your gateway on whatever network - which is normally by common practice either the 1st IP or the last on a network.
But sure go ahead if you want - but there is no reason they should be just shotgunned into the ip network.. put them on one side of the pool ;)
But also not just loopback on your routers or switches.. But normally their management IP on its own infrastructure network anyway. Servers of some kind would be on their own normally as well. But sure there might be some static stuff on any network. The gateway device, dns or dhcp server itself, etc. Common practice is to leave a few ips on each side of the scope.. We normally start at .10 and end at .244.
-
@johnpoz said in pfsense DHCP Reservation Questions:
@P3R where did you quote that from ;)
I quoted you and it says so in the first line of that post. It's the same in this one.
But sure go ahead if you want - but there is no reason they should be just shotgunned into the ip network.. put them on one side of the pool ;)
I'm not the OP and I have them outside of the pool, bottom and top. I just explained why some may use static and I don't need the approval.
I reserve them in DHCP as well though. That way the DHCP configuration is at the same time my IP documentation and it prevent any problems should there be a factory reset of a device. A little more work initially but less problems later on.
But also not just loopback on your routers or switches.. But normally their management IP on its own infrastructure network anyway. Servers of some kind would be on their own normally as well.
True for professional users and equipment but not for many home users.
-
@P3R said in pfsense DHCP Reservation Questions:
I quoted you and it says so in the first line of that post. It's the same in this one.
not not me - this part, this sounds like it came from doc from back in the day on why static is better
"Because it prevent the most important infrastructure devices in the network to remain on their well-known IPs"
True for professional users and equipment but not for many home users.
Sure - true, but what is the point of breaking up your pool and putting IPs inside your continuous space.. Just leave some in the beginning and leave some at the end for your reservations and statics.. A pool of .10 to .244 leaves you 20 ips for static or reservations - if you need more use .20 to .234, etc. or 100-200 as your pool.
What does it matter if device X is .9 or .90 ? or .128 or .156 or .245, etc..
-
@johnpoz said in pfsense DHCP Reservation Questions:
not not me - this part, this sounds like it came from doc from back in the day on why static is better...
Ah okay. It wasn't a quote, those were my own words. I don't mind that you mock me for being old-school because that's what I am.
Sure - true, but what is the point of breaking up your pool and putting IPs inside your continuous space..
Maybe I was unclear but I'll try again. I don't do what you say there.
It is the OP that like it that way but I'm not him.I have my static and reserved IPs in the beginning and at the end of the IP subnet and the pool in the middle so very similar to your recommendation.
-
@johnpoz said in pfsense DHCP Reservation Questions:
Its good practice to not set static ips inside your pool, that is why you should edit the pool to leave ips off on the beginning and end for static or reservations.
Well question for you. When i set up printers those are done with DHCP. Grab the DHCP so i can grab the MAC address and then create a static outside of the pool, restart the printer, its all a bit much, no? Its easier to make a static once it grabs an IP.
-
@johnpoz disregard i see your workflow above in a previous comment.