In my office, I have a printer with static IP 192.168.0.254/24
. Normally, it should be excluded from the DHCP pool in the router. So I just set the DHCP pool to be in the range of 192.168.0.2/24 - 192.168.0.240/24
, 192.168.0.241/24 - 192.168.0.254/24
will be left for some machines that require static IP like the printer.
Then I also added the static IP 192.168.0.254/24
in the router for the printer. It seems there's nothing wrong. But with these settings, the printer is inaccessible to other machines in the same network. That is, nobody is able to print from their computer and it doesn't respond to any PING
request like before.
I had completely no idea. So I just tried some luck by configuring the DHCP range to cover as most IPs as it can, which is 192.168.0.2/24 - 192.168.0.254/24
.
After router restart, the printer is now completely accessible and can respond to PING
just like it was before we replaced the old router with this one (Cisco RV180W).
So my question is, shouldn't we exclude a static IP from the DHCP pool?
I have included some screenshots below that show our current configuration:
Note: you can see there are some machines using static IPs but I still haven't added them in the Static DHCP Client Table
because I plan to change them to use dynamic IP later.
I'm going to preface this answer (that I already typed out, and am thus, not going to delete) by saying that it looks like your router uses the term "static DHCP" for what the rest of the world calls a "DHCP reservation."
So, in fact, the proper configuration of your device is to have your DHCP pool set from
192.168.0.2
to192.168.0.254
, and then to put all those static addresses I see in the LAN hosts table into the "Static DHCP" client table. (If you don't put them in the Static DHCP table, the DHCP server may assign those IP addresses to another device, creating an IP conflict.)Also...
/24
) is not correct, and confusing.192.168.0.241/24
is not a valid subnet. It's192.168.0.0/24
. The/24
indicates that it is a 24 bit subnet composed of 256 IP addresses.Anyway, moving onto the general case...
In short, yes. You should exclude any statically-assigned IP addresses from being assigned from your DHCP pool. If you don't, your DHCP server will happily assign that static IP address to a device requesting a DHCP-assigned address, and you'll end up with an IP conflict, and some potentially confusing connection issues reported by your users.
As to how you typically accomplish this, there are basically three ways.