Page 1 of 1

DHCP Setup on two ports

Posted: Wed Jan 09, 2019 10:58 pm
by nine1ron
I need to setup two dhcp lease pools on my network so that traffic is on different pools. Every time I try add a dhcp server and link it to an interface, it says its set as a slave. My goal is to have port 2 set with a 192.168.75.1/24 pool and port 3 set as a 192.168.80.1/24 pool. I know it has to do with the bridge but am not figuring out what I am doing wrong. I have internet working on it where port 1 is my WAN and port 5 is directly connected to my computer. Can anyone point me in the right direction? My goal is for all data to go out the WAN port for internet but to keep traffic separate on the two ports.

Re: DHCP Setup on two ports

Posted: Thu Jan 10, 2019 7:08 pm
by anav
What router and what firmware version are you using please.

Re: DHCP Setup on two ports

Posted: Thu Jan 10, 2019 7:34 pm
by AlainCasault
Hello,

I'm afraid your question is all over the place. Dhcp, traffic flow...

I'll answer the dhcp question: assign your dhcp server to the bridge hosting the two ports. As the router is saying, you can't assign the server to a port inside a bridge.

Cheers,


Sent from my cell phone. Sorry for the errors.


Re: DHCP Setup on two ports

Posted: Thu Jan 10, 2019 7:43 pm
by Exiver
Its not possible to add the dhcp server on a bridged interface because those ports are logically connected like on a switch. That means the dhcp service on slave interface (ether6) would also listen on slave interface (ether7). That results into the problem that the service cannot distinguish from which client (on ether6 or ether7?) the request was sent (and here you would need the deicision if it should hand out a ip from pool 1 or pool 2).

You need to make a decision: What are you trying to do. Should devices from pool 1 be able to connect to devices from pool 2 (and vice versa)? Or do you want them to be seperated? Sometimes you only need one or more specific devices from one network to reach one or more devices in the other network.

Your options are:
- Route the traffic between both networks (make sure to have proper firewall rules) -> you dont need a bridge for the two networks, just assign the dhcp service to the specific ethernet port.
- Have them in a bridged network and setup ip addresses in /ip dhcp-server leases statically for the clients (you do not need pools for that, but you need two entries in /ip dhcp-server network)

Re: DHCP Setup on two ports

Posted: Fri Jan 11, 2019 5:57 pm
by AlainCasault

Its not possible to add the dhcp server on a bridged interface because those ports are logically connected like on a switch. That means the dhcp service on slave interface (ether6) would also listen on slave interface (ether7). That results into the problem that the service cannot distinguish from which client (on ether6 or ether7?) the request was sent (and here you would need the deicision if it should hand out a ip from pool 1 or pool 2).

You need to make a decision: What are you trying to do. Should devices from pool 1 be able to connect to devices from pool 2 (and vice versa)? Or do you want them to be seperated? Sometimes you only need one or more specific devices from one network to reach one or more devices in the other network.

Your options are:
- Route the traffic between both networks (make sure to have proper firewall rules) -> you dont need a bridge for the two networks, just assign the dhcp service to the specific ethernet port.
- Have them in a bridged network and setup ip addresses in /ip dhcp-server leases statically for the clients (you do not need pools for that, but you need two entries in /ip dhcp-server network)
Don't want to be rude, but this answer is as confusing as the question. I think the OP has to refine his request.

Just to clear one point, if you have two ports in one bridge, the dhcp server goes on the bridge, nowhere else. If you want one port to use one pool, and the other another pool, you don't bridge them. They become separate subnets that will be able to communicate with each other without any problem. Of course, both ports will have their own ip address. The firewall is only added after to restrict communications. Routing is not even required since both subnets are on the same router.

Cheers,

Sent from my cell phone. Sorry for the errors.


Re: DHCP Setup on two ports

Posted: Fri Jan 11, 2019 6:23 pm
by AlainCasault
Well, you are rude and you're not very understanding.

If you read the original question:
request is to setup two different dhcp server configuraiton for two ports which are seemingly in same bridge configuration. What's so hard to understand?

If you're not willing to help, then don't bother others trying to do just that.
Thank you for that curtious reply.

And your contribution to this post is???

Anyway, I have replied to the question asking for more info, and corrected the previous post which was inacurate and misleading to the OP. What's your answer then?

Re: DHCP Setup on two ports

Posted: Fri Jan 11, 2019 9:17 pm
by sebastia
My comment was purely on form and manner, if it wasn't obvious enough...

Re: DHCP Setup on two ports

Posted: Fri Jan 11, 2019 9:31 pm
by AlainCasault
My comment was purely on form and manner, if it wasn't obvious enough...

Next time, report my post and let a real moderator tell me what to do.