MT + dhcp server + relay

How do you setup MT’s dhcp server to handle relay networks?

set ‘Relay’ to relay’s IP (or 255.255.255.255 for accepting requests from any relay)

So in that case MT dhcp-server may be far away more then one hop from dhcp-server ? client — dhcp relay — dhcp relay — … — dhcp server ?

no, it cannot.

janisk, why not?.. =)

El-Emin, you do not need such configuration, as I can see. Just set server’s IP on all relays - and they will use unicast packets for communicating with server. E.g., DHCP Relays on switches (DGS-3028) with DHCP Snooping do not intercept unicast DHCP requests

Chupaka, thanks I`ll try it.
I want to set up one dhcp server with public ips for pppoe users and redistribute connected users with osfp. I hope u understand my idea ? :slight_smile:

hmmm… it might work =)

I have done that. This is the setup.


inet ---- MT1 ----- MT2 ----- MT3 -----Client.

It does not matter what I use at the client for the relay, It always assigns a IP from the dhcp server MT1. How do you tell MT1 to use the giaddr to assign something from the network at the relay and not from its local pool. ISC DHCP can do this with no problem.

what is your config?.. this MTs say about nothing… what do you want to achieve?

what is your config?.. this MTs say about nothing… what do you want to achieve?

Right now I have:

inet ---- MT1 — {network} — ClientRadio – ClientRouter.
|
|
\ - ISC DHCP

Where {network} can be 1 router or 5 routers deep.
ClientRadio can be MT, UBNT, Or a laptop with a Brand X radio.
ClientRouter can be MT, Cisco, Consumer Brand X, and I think a few Netopias
ISC DHCP is my current DHCP server for all relays.

All the ClientRouters are set as DHCPRelays with my ISC DHCP server as master.

My dhcpd.conf looks like:

subnet 10.8.254.0 netmask 255.255.255.0 {
option routers 10.8.254.1;
range 10.8.254.2 10.8.254.254;

subnet 10.8.255.0 netmask 255.255.255.0 {
option routers 10.8.255.1;
range 10.8.255.2 10.8.255.254;

etc, etc.

What this does is when a DHCP Request comes in with a giaddr of 10.8.254.1 it then assigns leases from the assigned range (10.8.254.2~10.8.254.254 in this case). Now if the lease is already in the lease file, they get the same address again, etc, just like local dhcp.

If MT’s dhcp server used the gateway=a.b.c.d to match the giaddr tag and then respond just as if it were a local request, it would work fine. Maybe it already works and I have just missed a obvious setting?

hmmm… try to add several dhcp servers with different ‘Relay’ IP addresses, and set different pools for these servers

I tried that, it still gives a error about giaddr.

an error?.. what error?..