01-16-2013 01:12 AM - edited 03-07-2019 11:06 AM
hi ,
i want to ask about dhcp in MLS
1st thing , the pool is configured from the global config .....
now assume i have port of MLS as l3 port , and has the ip 192.168.1.1 255.255.255.0
if i configured a pool that has range 192.168.1.2 255.255.255.0 and has the subnet 192.168.1.0/24 and the gateway is 192.168.1.1
where will the switch start assigning the ips ??
i mean based on what , the MLS will let the interface 192.168.1.1 to start assigning ips to clinets ??
what is the rule for that ?? is it based on the MLS ip is from the subnet in the poool ??
assume that i have another interface has an ip 172.16.1.1
will that interface assign the ips from the subnet 192.168.1.0/24 to the hosts ???? or just the interface of the ip 192.168.1.1 will start to assing the ips to the hosts
here is my main question .... based on what ????
im getting confusing .
regards
01-16-2013 01:44 AM
Hi,
if i configured a pool that has range 192.168.1.2 255.255.255.0 and has the subnet 192.168.1.0/24 and the gateway is 192.168.1.1
I suppose you meant a pool of 192.168.1.0 /24 not 1.2 unless you talked about a static mapping with a host pool ?
If it was a "normal pool" then it would assign starting from 192.168.1.2 even if you had not excluded 192.168.1.1 because it will ping the ip address it wants to lease before giving it out and as it will receive a reply it will go to following address.
Now even if it had not verified this, the host would send a gratuitous arp request and as it would receive a reply it would send a dhcp decline to the server for 192.168.1.1 and would propose the next IP in the range.
assume that i have another interface has an ip 172.16.1.1
will that interface assign the ips from the subnet 192.168.1.0/24 to the hosts ???? or just the interface of the ip 192.168.1.1 will start to assing the ips to the hosts
here is my main question .... based on what ????
im getting confusing .
regards
If you don't have a corresponding pool for this other subnet then you will get no IP from this subnet from DHCP, Its not the interfaces that serve the IP addresses but the device as a whole and the interface on which the DHCP discover is received is used to choose the pool from which to lease out addresses.
Regards.
Alain.
01-16-2013 01:46 AM
The DHCP will now the correct subnet from the request's GIADDR field, so it won't assign addresses from 192.168.1.0/24 to hosts in the 172.26.1.0/24 subnet.
01-16-2013 01:48 AM
hi , thanks alot .
so ,
in summary
the L3 interface subnet must be from the pool subnet so that L3 interface assing ips fro this pool
assume i execluded the L3 ip.
am i right ?
01-16-2013 01:58 AM
Hi,
As I explained above the interface is not responsible of leasing out IPs but it may be used to derive which pool to use to get an IP from to lease it out.
Regards.
Alain.
Don't forget to rate helpful posts.
01-16-2013 02:00 AM
this is the point i want to ask about ...
the L3 interface change the pool .
so , the L3 subnet must be in the same as pool subnet so that the specific pool deployed by the interface ???
am i right ?
regards
01-16-2013 03:19 AM
Hello,
yes you are right. There are some notes.
The DHCP request is sent by the client and is processed at L3 by the receiving L3 interface on the MLS switch, in this way the L3 interface provides the context so that a free IP address is chosen from the appropriate DHCP pool when the pool is locally defined.
On the other hand, the L3 interface on the MLS switch has to act as the default gateway for the hosts so both the L3 interface and the hosts must be in the same IP subnet. This is required.
When the DHCP server is located in another device the MLS switch can act as a DHCP relay agent and as it has been explained by Andras, an internal field in the DHCP packet is modified with the L3 interface IP address that received the original request to provide context. The destination address is changed from broadcast address that cannot be routed to the unicast IP address of the DHCP server as specified in the ip helper-address command applied under the receiving L3 interface.
The DHCP server replies to the Giaddr address (the internal field mentioned above) with a DHCP offer that contains the address taken from the right pool
Hope to help
Giuseppe
Discover and save your favorite ideas. Come back to expert answers, step-by-step guides, recent topics, and more.
New here? Get started with these tips. How to use Community New member guide