Multiple DHCP clients on interface

Started by jysky, September 08, 2020, 09:16:49 PM

Previous topic - Next topic
I've been trying to figure out how one would go about configuring multiple DHCPv4 clients for single interface. So my ISP gives out 5 IPv4 addresses with DHCP and I would like to have all 5 IPv4 addresses on my WAN interface.

The closest one about this was sort of multi wan configuration with load balancing, but that doesn't really help me with multiple DHCP clients.

Any ideas how to configure multiple DHCP clients?

Are these not statically assigned? You cannot run more than one DHCP on a single link as it utilizes broadcasting...


Cheers,
Franco

I'm starting with opnsense, still, I would suggest to check if multiwan can do what you are after.

Multi-WAN, sure but following up on the OP:

> multiple DHCPv4 clients for single interface

Multi-WAN means multiple interfaces.

The only setup I know is setting VIPs or 1:1 NAT mappings for a single interface... but as I said it mandates a static address pool to avoid DHCP in the first place (at least for the aux IP addresses, maybe not for the main one).


Cheers,
Franco

Unfortunately can't have static IPs. On linux I would just create macvlan virtual interface for physical interface and assing additional DHCP clients to those virtual interfaces. As far as I understand this is not possibility with opnsense, correct me if I'm mistaken.

With virtual interfaces multi wan configuration might become more relevant.

Quote from: jysky on September 09, 2020, 02:52:10 PM
Unfortunately can't have static IPs. On linux I would just create macvlan virtual interface for physical interface and assing additional DHCP clients to those virtual interfaces. As far as I understand this is not possibility with opnsense, correct me if I'm mistaken.

With virtual interfaces multi wan configuration might become more relevant.

You can have static IP on linux, you just have to set them manually same way you do it on Windows (people just use console commands rather than GUI on linux).

Anyway, the answer to topics question is no.

You can't have more than 1 public IP address per interface. You can have multiple different networks which DHCP requests and answers go thru 1 interface, that's called DHCP relay and requires static or dynamic route and nerves of steel to configure (Routes are something which either make you feel like god or make you feel like jumping infront of a moving train)