I would like to implement two routers in one

Started by e1e0n, May 20, 2023, 01:01:23 AM

Previous topic - Next topic
I would like to implement two routers in one, ie I would like to have 2 WAN and 2LAN ports. Traffic should be isolated. I can't select ip4 gataway for LANs :(. pfSense allows this easily. Please, how can I do that? Default setting would just choose one upstream gateway and use it. I tried setting Firewall rules but they don't seem to work :((((

This works perfectly well if done correctly. Please show your configuration - just two sentences stating "it doesn't work" is too little information to help you.

Essentially you need to

- set up 2 WAN ports and gateways
- set up 2 LAN ports without gateways
- set NAT to manual
- create two outbound NAT rules - one for each WAN port with one of the LAN networks as source
- create two permit rules - one for each LAN ports, explicitly setting the desired WAN gateway

HTH,
Patrick
Deciso DEC750
People who think they know everything are a great annoyance to those of us who do. (Isaac Asimov)

Thanks, I though about that, full manual, but I am not very confident in doing that :) Will the auto generated rules be preserved? Do I need to recreate bunch of all other autogenerated rules? I don't really understand many of them. Would be nice to have ability just to override them. I was suspicious that autogenerated rules are messing with me :)

You need just one manual NAT rule for each WAN interface. I run all my OPNsense firewalls in manual NAT mode.
Deciso DEC750
People who think they know everything are a great annoyance to those of us who do. (Isaac Asimov)


Quote from: pmhausen on May 20, 2023, 11:08:09 AM
This works perfectly well if done correctly. Please show your configuration - just two sentences stating "it doesn't work" is too little information to help you.

Essentially you need to

- set up 2 WAN ports and gateways
- set up 2 LAN ports without gateways
- set NAT to manual
- create two outbound NAT rules - one for each WAN port with one of the LAN networks as source
- create two permit rules - one for each LAN ports, explicitly setting the desired WAN gateway

HTH,
Patrick

for >> - create two permit rules - one for each LAN ports, explicitly setting the desired WAN gateway

When I set Gateway in LAN rules (to WAN_DHCP in my case) it blocks traffic. Setting to '*' enables. I am at the dead end  :(