Basic Multi LAN, Multi WAN home router
-
I set up a home router with basic 2 port LAN and 2 port WAN (pppoe) configuration (total 4 physical LAN port). where user using LAN 1 as gateway will automatically assigned to WAN 1 and user using LAN 2 will be assigned to WAN2.
It worked, however the traffic graph is not showing right. The outgoing traffic of WAN2 is correctly showing as incoming in LAN2 but the incoming traffic of WAN2 are showing as outgoing traffic of LAN1. This is not right because the incoming traffic of WAN2 should be showing as outgoing traffic of LAN2.
attached the screenshot
May i know is there something wrong i did or is a bug?
by the way
LAN1 192.168.100.1/24
LAN2 192.168.100.2/24WAN1 pppoe0
WAN2 pppoe1The reason i did this because that there are multiple users in my home and whoever downloading and surfing uses 192.168.100.1 as gateway and online gaming uses 192.168.100.2 as gateway.
-
LAN1 192.168.100.1/24
LAN2 192.168.100.2/24The problem is that your two LANs sit on the same subnet. There's no way to route this properly.
whoever downloading and surfing uses 192.168.100.1 as gateway and online gaming uses 192.168.100.2 as gateway
The simpler and more correct way to do this is to have a single LAN and use pfsense to route traffic based on traffic type, for example by destination port. So traffic destined to ports 80 and 443 will use WAN as gatway, and everything else will use WAN2. You can get more specific than that, but you get the idea.
-
LAN1 192.168.100.1/24
LAN2 192.168.100.2/24The problem is that your two LANs sit on the same subnet. There's no way to route this properly.
I don't have a problem doing this while I have 2 piece of router hardware.
and why there is a problem that 2 LAN sits in the same subnet?
if i assign the LAN1 and 2 to different subnet,
e.g.
LAN 1 192.168.101.1
LAN 2 192.168.102.1how can i let my client "change gateway" or "use both gateway" without changing my client's IP?
whoever downloading and surfing uses 192.168.100.1 as gateway and online gaming uses 192.168.100.2 as gateway
The simpler and more correct way to do this is to have a single LAN and use pfsense to route traffic based on traffic type, for example by destination port. So traffic destined to ports 80 and 443 will use WAN as gatway, and everything else will use WAN2. You can get more specific than that, but you get the idea.
Can't do this, because traffic type always change and too complex due to different online games. Also i have cases that 2 same traffic type using different WAN (e.g. huge game updates and it is much more efficient to assign manually by changing the gateway at the client side because applying any changes on the pfsense breaks ALL connection which will create huge outrage.).
by the way, having weird stats on my LAN connection.
-
figured out the solution.
LAN1 192.168.100.1/24
LAN2 192.168.101.1/24For every client, i add a virtual IP so they belong to both subnet.
e.g.
Client1
IP: 192.168.100.11/24
Virtual IP: 192.168.101.11/24Client2
IP: 192.168.100.12/24
Virtual IP: 192.168.101.12/24Client3
IP: 192.168.100.13/24
Virtual IP: 192.168.101.13/24Client4
IP: 192.168.100.14/24
Virtual IP: 192.168.101.14/24It worked normally now, hopefully without problems after i put in the traffic shaping rules.
Thanks for the advice.