Separates VLANs with the same IP-Range

Simon Hobson simon at thehobsons.co.uk
Fri Apr 26 18:50:38 UTC 2019


perl-list <perl-list at network1.net> wrote:

>> is it possible to configure a DHCP Server with multiple Relay-Servers identified
>> via option 82(remote-id) for separates VLANs like the following example. If
>> yes, how to set up?
> 
>> DHCP-Server(10.0.3.24/24)
>> Relay1(10.0.3.55/24 and 192.168.0.1/24) -> offer IP-Range 192.168.0.100 - 150
>> Relay2(10.0.3.70/24 and 192.168.0.1/24) -> offer IP-Range 192.168.0.100 - 150


> I'm not sure how option 82 remote-id relates to the below, but you could cause both relays to allocate from the same ip range by setting up a shared network like this:
> 
> shared-network SomeNetwork {
>     subnet 192.168.0.0 netmask 255.255.255.0 {
>          range 192.168.0.100 192.16.0.150;
>     }
>     subnet 10.0.3.0 netmask 255.255.255.0 {
>          # This will link the 10.0.3.0/24 subnet to the 192.168.0.0/24 subnet for address allocation purposes.
>          # any relayed DHCP traffic from source 10.0.3.55 or 10.0.3.70 will cause the DHCP server to allocate 
>          # an address from 192.168.0.0/24
>     }
> } 

That will not work - or rather, DHCP will not work in the network described.
The OP wants to run the same IP subnet on two separate networks. That is not supported as there is no way to make it work.
In theory it could be possible to handle relayed traffic via some sort of fudge, but not all DHCP traffic is relayed. When a client contacts the server directly by unicast (eg to renew an active lease) then the server has a problem - if does not know which network the packet came from, and there is no way to send the return packet back.

Fundamental rule of IP - addresses must be globally unique. NAT breaks this, but in the context of the query, IP addresses must be unique within the realm serviced by the DHCP server. This is not a DHCP limitation, it is a basic IP limitation - if addresses are not unique, then you can't build routing tables for them.



More information about the dhcp-users mailing list