More than one DHCP ranges in the same network segment

Hi guy,
I want to know if it’s possibile to have in Nethserver 7 release more than one DHCP ranges in the same network segment.

My current server (linux server, Debian 8 with isc-dhcp-server) has more than one DHCP range with IP address reservation (no free lease dynamic range only static) but in Nethserver I don’t see a similar GUI configuration.

Thanks a lot

1 Like

I’m interested too.

which is the aim? I mean… different segments in the same subnet…

It happens when you are out of IP in a segment and can’t expand it because near to it there are configured printers/cams/servers/scanners/someotherthings that have fixed IP. (real experience…)

you’re right, indeed… thank you

AFAIK, dnsmasq (NethServer dhcp server) will not assign fixed ip within the range.
Real world scenario: green network:, dhcp range, many fixed ip addresses scattered in the range (printers, voip gateways, cams, etc), never seen an ip conflict in years.

1 Like

So, i have a printer with ip that it’s turned off at the moment.
I set up the DHCP server and a client have assigned from the DHCP server.
Then, i turn on the printer…

I think you can generate via template-custom

mkdir -p /etc/e-smith/templates-custom/etc/dnsmasq.conf
cd /etc/e-smith/templates-custom/etc/dnsmasq.conf

vi 31dhcp




save the file then

expand-template /etc/dnsmasq.conf

and restart the service


Search for --dhcp-range parameter

1 Like

Thanks for the suggestions.
I’m not really sure you understood what i said, so my question was: is it possible to realize a “shared-network”?

shared network: the situation where you run multiple IP subnets on the same wire.

for example in isc-dhcp-server the lines are:
shared-network demo {
subnet …
subnet …

Could I try to create a template by the way you suggested me?

you’re asking for different subnets with enabled dhcp :slight_smile:

yes two dhcp subnets with fixed IP released by mac.

1 Like

That is when VLAN kicks in, right? Otherwise you will have a big mess when you don’t use DHCP reservations.

In my current enviroment I don’t have any VLAN configuration but I have a DHCP reservation for all the hosts of organization
Clients correctly takes own configuration from DHCP server:
-clients with a fixed IP of subnet 1 and fixed MAC takes network parameters of subnet 1
-clients with a fixed IP of subnet 2 and fixed MAC takes network parameters of subnet 2

network parameters of subnet 1 and subnet 2 are globally definited in DHCP configuration file.
Only one network physical card on linux server with 2 logical subnet defined in dhcp configuration

Just playing the devils advocate here: What happens when a device enters your network that has no IP address reservation? It will get an IP in one or the other subnet. But it will be unpredictable what IP range. IMO this is a situation you want to prevent (the unpredictable part).

1 Like

Looks like a nightmare :fearful: